7 (setq-default |
7 (setq-default |
8 ediff-split-window-function 'split-window-horizontally ; diff horizontally |
8 ediff-split-window-function 'split-window-horizontally ; diff horizontally |
9 x-select-enable-clipboard t ; paste from X buffer |
9 x-select-enable-clipboard t ; paste from X buffer |
10 inhibit-splash-screen t ; disable splash screen |
10 inhibit-splash-screen t ; disable splash screen |
11 truncate-lines t ; truncate, not wrap, lines |
11 truncate-lines t ; truncate, not wrap, lines |
12 indent-tabs-mode nil) ; mouse hover variables |
12 indent-tabs-mode nil ; mouse hover variables |
|
13 split-width-threshold 181) ; min width to split window horizontially |
13 |
14 |
14 (put 'set-goal-column 'disabled nil) ; enable goal column setting |
15 (put 'set-goal-column 'disabled nil) ; enable goal column setting |
15 (put 'narrow-to-region 'disabled nil) ; enable hiding |
16 (put 'narrow-to-region 'disabled nil) ; enable hiding |
16 |
17 |
17 (menu-bar-mode nil) ; remove menu bar |
18 (menu-bar-mode nil) ; remove menu bar |
20 (delete-selection-mode t) ; replace highlighted text |
21 (delete-selection-mode t) ; replace highlighted text |
21 (windmove-default-keybindings) ; move between windows with shift-arrow |
22 (windmove-default-keybindings) ; move between windows with shift-arrow |
22 (ido-mode t) ; file/buffer selector |
23 (ido-mode t) ; file/buffer selector |
23 (setq-default ido-enable-flex-matching t) ; fuzzy matching for ido mode |
24 (setq-default ido-enable-flex-matching t) ; fuzzy matching for ido mode |
24 (add-hook 'text-mode-hook 'flyspell-mode t) ; spellcheck text |
25 (add-hook 'text-mode-hook 'flyspell-mode t) ; spellcheck text |
25 (add-hook 'text-mode-hook 'turn-on-aut-fill) ; autofill text |
26 (add-hook 'text-mode-hook 'turn-on-auto-fill) ; autofill text |
26 |
27 |
27 ;; whitespace |
28 ;; whitespace |
28 (global-whitespace-mode t) ; show whitespace |
29 (global-whitespace-mode t) ; show whitespace |
29 (add-hook 'before-save-hook 'whitespace-cleanup) ; cleanup whitespace on exit |
30 (add-hook 'before-save-hook 'whitespace-cleanup) ; cleanup whitespace on exit |
30 (setq-default |
31 (setq-default |
36 ;; coding |
37 ;; coding |
37 (which-func-mode t) ; show current function |
38 (which-func-mode t) ; show current function |
38 (show-paren-mode t) ; show matching paren |
39 (show-paren-mode t) ; show matching paren |
39 (transient-mark-mode t) ; show highlighting |
40 (transient-mark-mode t) ; show highlighting |
40 (global-font-lock-mode t) ; syntax highlighting |
41 (global-font-lock-mode t) ; syntax highlighting |
|
42 (setq-default compile-command "scons ") ; compile command |
41 (global-set-key (kbd "C-c c") 'compile) ; compile |
43 (global-set-key (kbd "C-c c") 'compile) ; compile |
42 (global-set-key (kbd "C-c r") 'recompile) ; recompile |
44 (global-set-key (kbd "C-c r") 'recompile) ; recompile |
|
45 (global-set-key (kbd "C-c C-c") ; comment |
|
46 'comment-or-uncomment-region) |
43 |
47 |
44 ;; includes |
48 ;; includes |
45 (require 'hoersten-pastebin-region) ; send selected text to pastebin |
49 (require 'hoersten-pastebin-region) ; send selected text to pastebin |
46 (require 'mercurial) ; load mercurial mode |
|
47 (require 'hoersten-c-style) ; load c specific lisp |
50 (require 'hoersten-c-style) ; load c specific lisp |
|
51 (require 'hide-lines) ; hide lines based on regexp |
|
52 (require 'vala-mode) ; vala programming language |
|
53 |
|
54 ;; Xrefactory |
|
55 ;; (setq load-path (cons "~/xref/emacs" load-path)) |
|
56 ;; (setq exec-path (cons "~/xref" exec-path)) |
|
57 ;; (load "xrefactory") |
|
58 |
|
59 ;; iedit mode |
|
60 (require 'iedit) ; interactive edit mode |
|
61 (define-key global-map (kbd "C-;") 'iedit-mode) |
48 |
62 |
49 ;; nav mode |
63 ;; nav mode |
50 (add-to-list 'load-path "~/.emacs.d/nav/") |
64 (add-to-list 'load-path "~/.emacs.d/nav/") |
51 (require 'nav) |
65 (require 'nav) |
52 |
66 |
69 (require 'uniquify) |
83 (require 'uniquify) |
70 (setq |
84 (setq |
71 uniquify-buffer-name-style 'post-forward |
85 uniquify-buffer-name-style 'post-forward |
72 uniquify-separator ":") |
86 uniquify-separator ":") |
73 |
87 |
74 ;; shell |
88 ;; terminal and shell |
75 (global-set-key (kbd "C-c s") 'shell) ; start shell |
89 (global-set-key (kbd "C-c t") '(lambda () (interactive) (ansi-term "bash" "term"))) ; start term |
|
90 (global-set-key (kbd "C-c s") 'shell) ; start shell - acts like emacs buffer |
76 (ansi-color-for-comint-mode-on) ; color in shell buffer |
91 (ansi-color-for-comint-mode-on) ; color in shell buffer |
77 (setq-default |
92 (setq-default |
78 comint-scroll-to-bottom-on-input t ; only type on prompt |
93 comint-scroll-to-bottom-on-input t ; only type on prompt |
79 comint-scroll-show-maximum-output t) ; place text at bottom |
94 comint-scroll-show-maximum-output t) ; place text at bottom |
80 |
95 |