author | Luke Hoersten <luke@hoersten.org> |
Sun, 16 Feb 2020 14:02:12 -0600 | |
changeset 103 | f76683958fb4 |
parent 102 | c87589ea77d5 |
permissions | -rw-r--r-- |
103 | 1 |
;;; init --- Summary: Luke Hoersten <[email protected]> personal init file |
2 |
||
3 |
;;; Commentary: |
|
4 |
;;; ~/.emacs.d/init.el (~/.emacs) |
|
0 | 5 |
|
100 | 6 |
;;; Code: |
75 | 7 |
(add-to-list 'load-path "~/.emacs.d/elisp") ; set default emacs load path |
0 | 8 |
|
21 | 9 |
(setq-default |
82
12cf67bc486c
Added paredit, flx-ido and projectile.
Luke Hoersten <luke@hoersten.org>
parents:
78
diff
changeset
|
10 |
gc-cons-threshold 20000000 ; gc every 20 MB allocated (form flx-ido docs) |
75 | 11 |
inhibit-splash-screen t ; disable splash screen |
12 |
truncate-lines t ; truncate, not wrap, lines |
|
13 |
indent-tabs-mode nil ; only uses spaces for indentation |
|
14 |
split-width-threshold 181 ; min width to split window horizontially |
|
15 |
split-height-threshold 120 ; min width to split window vertically |
|
16 |
reb-re-syntax 'string ; use string syntax for regexp builder |
|
99
c50532aea1f3
Added haskell compile command.
Luke Hoersten <luke@hoersten.org>
parents:
98
diff
changeset
|
17 |
fill-column 120 ; line width |
75 | 18 |
require-final-newline 'visit-save) ; add a newline automatically |
0 | 19 |
|
75 | 20 |
(put 'set-goal-column 'disabled nil) ; enable goal column setting |
21 |
(put 'narrow-to-region 'disabled nil) ; enable hiding |
|
21 | 22 |
(put 'narrow-to-page 'disabled nil) |
23 |
||
85
0b91f7fe5a89
Reorganized global modes a bit. Fixed multi-frame font changes.
Luke Hoersten <luke@hoersten.org>
parents:
84
diff
changeset
|
24 |
(fset 'yes-or-no-p 'y-or-n-p) ; replace yes/no prompts with y/n |
0b91f7fe5a89
Reorganized global modes a bit. Fixed multi-frame font changes.
Luke Hoersten <luke@hoersten.org>
parents:
84
diff
changeset
|
25 |
(windmove-default-keybindings) ; move between windows with shift-arrow |
0b91f7fe5a89
Reorganized global modes a bit. Fixed multi-frame font changes.
Luke Hoersten <luke@hoersten.org>
parents:
84
diff
changeset
|
26 |
|
75 | 27 |
(column-number-mode t) ; show column numbers |
28 |
(delete-selection-mode t) ; replace highlighted text |
|
85
0b91f7fe5a89
Reorganized global modes a bit. Fixed multi-frame font changes.
Luke Hoersten <luke@hoersten.org>
parents:
84
diff
changeset
|
29 |
(which-function-mode t) ; function name at point in mode line |
0b91f7fe5a89
Reorganized global modes a bit. Fixed multi-frame font changes.
Luke Hoersten <luke@hoersten.org>
parents:
84
diff
changeset
|
30 |
(transient-mark-mode t) ; highlight selection between point and mark |
0b91f7fe5a89
Reorganized global modes a bit. Fixed multi-frame font changes.
Luke Hoersten <luke@hoersten.org>
parents:
84
diff
changeset
|
31 |
(electric-pair-mode t) ; automatically close opening characters |
75 | 32 |
(global-font-lock-mode t) ; syntax highlighting |
85
0b91f7fe5a89
Reorganized global modes a bit. Fixed multi-frame font changes.
Luke Hoersten <luke@hoersten.org>
parents:
84
diff
changeset
|
33 |
(global-subword-mode t) ; move by camelCase words |
0b91f7fe5a89
Reorganized global modes a bit. Fixed multi-frame font changes.
Luke Hoersten <luke@hoersten.org>
parents:
84
diff
changeset
|
34 |
(global-hl-line-mode t) ; highlight current line |
75 | 35 |
(global-set-key (kbd "C-c c") 'compile) ; compile |
36 |
(global-set-key (kbd "C-c r") 'recompile) ; recompile |
|
37 |
(global-set-key (kbd "C-c a") 'align-regexp) ; align |
|
103 | 38 |
(global-set-key (kbd "C-c g") 'rg) ; rg |
45
12715da9a300
Changes to reflect Ubuntu 11.10 upgrade.
Luke Hoersten <Luke@Hoersten.org>
parents:
44
diff
changeset
|
39 |
|
0 | 40 |
|
86 | 41 |
;;; ediff |
42 |
(setq-default |
|
43 |
ediff-split-window-function 'split-window-horizontally |
|
44 |
ediff-window-setup-function 'ediff-setup-windows-plain) |
|
45 |
||
46 |
||
32
68b57950fa11
Fixed font problem and removed os-specific config files.
Luke Hoersten <Luke@Hoersten.org>
parents:
31
diff
changeset
|
47 |
;;; Darwin |
59
f346d7591eac
Removed more unused init code.
Luke Hoersten <Luke@Hoersten.org>
parents:
58
diff
changeset
|
48 |
(setq is-mac (equal system-type 'darwin)) |
f346d7591eac
Removed more unused init code.
Luke Hoersten <Luke@Hoersten.org>
parents:
58
diff
changeset
|
49 |
(when is-mac |
f346d7591eac
Removed more unused init code.
Luke Hoersten <Luke@Hoersten.org>
parents:
58
diff
changeset
|
50 |
(setq-default |
66
b6182e0be08d
Removed bell and added menu bar on OS X.
Luke Hoersten <Luke@Hoersten.org>
parents:
65
diff
changeset
|
51 |
ring-bell-function 'ignore |
59
f346d7591eac
Removed more unused init code.
Luke Hoersten <Luke@Hoersten.org>
parents:
58
diff
changeset
|
52 |
mac-command-modifier 'meta |
f346d7591eac
Removed more unused init code.
Luke Hoersten <Luke@Hoersten.org>
parents:
58
diff
changeset
|
53 |
ns-pop-up-frames nil |
f346d7591eac
Removed more unused init code.
Luke Hoersten <Luke@Hoersten.org>
parents:
58
diff
changeset
|
54 |
ispell-program-name "/usr/local/bin/aspell")) |
32
68b57950fa11
Fixed font problem and removed os-specific config files.
Luke Hoersten <Luke@Hoersten.org>
parents:
31
diff
changeset
|
55 |
|
78
7d7662fcc8d1
Started using shm and paredit.
Luke Hoersten <Luke@Hoersten.org>
parents:
77
diff
changeset
|
56 |
|
32
68b57950fa11
Fixed font problem and removed os-specific config files.
Luke Hoersten <Luke@Hoersten.org>
parents:
31
diff
changeset
|
57 |
;;; Xorg |
59
f346d7591eac
Removed more unused init code.
Luke Hoersten <Luke@Hoersten.org>
parents:
58
diff
changeset
|
58 |
(when window-system |
75 | 59 |
(tool-bar-mode -1) ; remove tool bar |
60 |
(scroll-bar-mode -1) ; remove scroll bar |
|
61 |
(unless is-mac (menu-bar-mode -1)) ; remove menu bar |
|
97
f7640b0bab67
Removed marmalade and rainbow-mode. Added ag package. Defaulted to Inconsolata on all OSs.
Luke Hoersten <luke@hoersten.org>
parents:
96
diff
changeset
|
62 |
(set-frame-font "Inconsolata-12" nil t)) |
31
27930e0310d6
Reorganized a ton. Split into 3 main sections: General, Modes, and Requires.
Luke Hoersten <Luke@Hoersten.org>
parents:
30
diff
changeset
|
63 |
|
78
7d7662fcc8d1
Started using shm and paredit.
Luke Hoersten <Luke@Hoersten.org>
parents:
77
diff
changeset
|
64 |
|
82
12cf67bc486c
Added paredit, flx-ido and projectile.
Luke Hoersten <luke@hoersten.org>
parents:
78
diff
changeset
|
65 |
;;;; Packages ;;;; |
96
8458091b7533
Updated to ssl emacs package repos.
Luke Hoersten <luke@hoersten.org>
parents:
94
diff
changeset
|
66 |
(package-initialize) |
82
12cf67bc486c
Added paredit, flx-ido and projectile.
Luke Hoersten <luke@hoersten.org>
parents:
78
diff
changeset
|
67 |
(require 'package-require) |
103 | 68 |
(package-require '(rg company exec-path-from-shell expand-region flx-ido |
94 | 69 |
smex markdown-mode markdown-mode+ hgignore-mode move-text paredit |
97
f7640b0bab67
Removed marmalade and rainbow-mode. Added ag package. Defaulted to Inconsolata on all OSs.
Luke Hoersten <luke@hoersten.org>
parents:
96
diff
changeset
|
70 |
rainbow-delimiters json-mode json-reformat flycheck |
82
12cf67bc486c
Added paredit, flx-ido and projectile.
Luke Hoersten <luke@hoersten.org>
parents:
78
diff
changeset
|
71 |
solarized-theme terraform-mode visual-regexp yasnippet yaml-mode |
12cf67bc486c
Added paredit, flx-ido and projectile.
Luke Hoersten <luke@hoersten.org>
parents:
78
diff
changeset
|
72 |
zencoding-mode)) |
12cf67bc486c
Added paredit, flx-ido and projectile.
Luke Hoersten <luke@hoersten.org>
parents:
78
diff
changeset
|
73 |
|
12cf67bc486c
Added paredit, flx-ido and projectile.
Luke Hoersten <luke@hoersten.org>
parents:
78
diff
changeset
|
74 |
|
12cf67bc486c
Added paredit, flx-ido and projectile.
Luke Hoersten <luke@hoersten.org>
parents:
78
diff
changeset
|
75 |
;;; custom requires |
94 | 76 |
(require 'haskell-intero-init) |
82
12cf67bc486c
Added paredit, flx-ido and projectile.
Luke Hoersten <luke@hoersten.org>
parents:
78
diff
changeset
|
77 |
(require 'javascript-init) |
12cf67bc486c
Added paredit, flx-ido and projectile.
Luke Hoersten <luke@hoersten.org>
parents:
78
diff
changeset
|
78 |
(require 'c-init) |
12cf67bc486c
Added paredit, flx-ido and projectile.
Luke Hoersten <luke@hoersten.org>
parents:
78
diff
changeset
|
79 |
(require 'ansible-init) |
12cf67bc486c
Added paredit, flx-ido and projectile.
Luke Hoersten <luke@hoersten.org>
parents:
78
diff
changeset
|
80 |
|
31
27930e0310d6
Reorganized a ton. Split into 3 main sections: General, Modes, and Requires.
Luke Hoersten <Luke@Hoersten.org>
parents:
30
diff
changeset
|
81 |
|
27930e0310d6
Reorganized a ton. Split into 3 main sections: General, Modes, and Requires.
Luke Hoersten <Luke@Hoersten.org>
parents:
30
diff
changeset
|
82 |
;;; text-mode |
75 | 83 |
(add-hook 'fundamental-mode-hook 'flyspell-mode) ; spellcheck text |
84 |
(add-hook 'fundamental-mode-hook 'turn-on-auto-fill) ; autofill text |
|
28
8f4bd2f2cc06
Aquamacs comes with more features so I removed some mac stuff.
Luke Hoersten <Luke@Hoersten.org>
parents:
26
diff
changeset
|
85 |
|
78
7d7662fcc8d1
Started using shm and paredit.
Luke Hoersten <Luke@Hoersten.org>
parents:
77
diff
changeset
|
86 |
|
31
27930e0310d6
Reorganized a ton. Split into 3 main sections: General, Modes, and Requires.
Luke Hoersten <Luke@Hoersten.org>
parents:
30
diff
changeset
|
87 |
;;; whitespace-mode |
75 | 88 |
(global-whitespace-mode t) ; show whitespace |
89 |
(add-hook 'before-save-hook 'whitespace-cleanup) ; cleanup whitespace on exit |
|
31
27930e0310d6
Reorganized a ton. Split into 3 main sections: General, Modes, and Requires.
Luke Hoersten <Luke@Hoersten.org>
parents:
30
diff
changeset
|
90 |
(setq-default |
75 | 91 |
whitespace-line-column 120 ; column width |
92 |
whitespace-style ; whitespace to highlight |
|
31
27930e0310d6
Reorganized a ton. Split into 3 main sections: General, Modes, and Requires.
Luke Hoersten <Luke@Hoersten.org>
parents:
30
diff
changeset
|
93 |
'(trailing lines-tail empty indentation |
27930e0310d6
Reorganized a ton. Split into 3 main sections: General, Modes, and Requires.
Luke Hoersten <Luke@Hoersten.org>
parents:
30
diff
changeset
|
94 |
space-before-tab space-after-tab)) |
21 | 95 |
|
78
7d7662fcc8d1
Started using shm and paredit.
Luke Hoersten <Luke@Hoersten.org>
parents:
77
diff
changeset
|
96 |
|
31
27930e0310d6
Reorganized a ton. Split into 3 main sections: General, Modes, and Requires.
Luke Hoersten <Luke@Hoersten.org>
parents:
30
diff
changeset
|
97 |
;;; org-mode |
21 | 98 |
(add-hook |
99 |
'org-mode-hook |
|
100 |
(lambda () |
|
101 |
(local-set-key (kbd "M-p") 'org-move-item-up) |
|
102 |
(local-set-key (kbd "M-S-p") 'org-move-subtree-up) |
|
103 |
(local-set-key (kbd "M-n") 'org-move-item-down) |
|
104 |
(local-set-key (kbd "M-S-n") 'org-move-subtree-down))) |
|
31
27930e0310d6
Reorganized a ton. Split into 3 main sections: General, Modes, and Requires.
Luke Hoersten <Luke@Hoersten.org>
parents:
30
diff
changeset
|
105 |
|
78
7d7662fcc8d1
Started using shm and paredit.
Luke Hoersten <Luke@Hoersten.org>
parents:
77
diff
changeset
|
106 |
|
32
68b57950fa11
Fixed font problem and removed os-specific config files.
Luke Hoersten <Luke@Hoersten.org>
parents:
31
diff
changeset
|
107 |
;;; ibuffer |
75 | 108 |
(global-set-key (kbd "C-x C-b") 'ibuffer) ; better buffer browser |
87
5e8b9d224e3e
Created dynamic major mode grouping for ibuffer.
Luke Hoersten <luke@hoersten.org>
parents:
85
diff
changeset
|
109 |
(require 'ibuffer) |
5e8b9d224e3e
Created dynamic major mode grouping for ibuffer.
Luke Hoersten <luke@hoersten.org>
parents:
85
diff
changeset
|
110 |
(require 'ibuf-ext) |
5e8b9d224e3e
Created dynamic major mode grouping for ibuffer.
Luke Hoersten <luke@hoersten.org>
parents:
85
diff
changeset
|
111 |
(defun ibuffer-generate-filter-groups-by-major-mode () |
5e8b9d224e3e
Created dynamic major mode grouping for ibuffer.
Luke Hoersten <luke@hoersten.org>
parents:
85
diff
changeset
|
112 |
(flet |
5e8b9d224e3e
Created dynamic major mode grouping for ibuffer.
Luke Hoersten <luke@hoersten.org>
parents:
85
diff
changeset
|
113 |
((mode-group |
5e8b9d224e3e
Created dynamic major mode grouping for ibuffer.
Luke Hoersten <luke@hoersten.org>
parents:
85
diff
changeset
|
114 |
(mode) |
5e8b9d224e3e
Created dynamic major mode grouping for ibuffer.
Luke Hoersten <luke@hoersten.org>
parents:
85
diff
changeset
|
115 |
(let ((mode-title |
5e8b9d224e3e
Created dynamic major mode grouping for ibuffer.
Luke Hoersten <luke@hoersten.org>
parents:
85
diff
changeset
|
116 |
(capitalize (car (split-string (symbol-name mode) "-" t))))) |
5e8b9d224e3e
Created dynamic major mode grouping for ibuffer.
Luke Hoersten <luke@hoersten.org>
parents:
85
diff
changeset
|
117 |
(cons mode-title `((mode . ,mode))))) |
5e8b9d224e3e
Created dynamic major mode grouping for ibuffer.
Luke Hoersten <luke@hoersten.org>
parents:
85
diff
changeset
|
118 |
(buffer-modes |
5e8b9d224e3e
Created dynamic major mode grouping for ibuffer.
Luke Hoersten <luke@hoersten.org>
parents:
85
diff
changeset
|
119 |
() |
5e8b9d224e3e
Created dynamic major mode grouping for ibuffer.
Luke Hoersten <luke@hoersten.org>
parents:
85
diff
changeset
|
120 |
(flet ((buffer-mode (buffer) (buffer-local-value 'major-mode buffer))) |
5e8b9d224e3e
Created dynamic major mode grouping for ibuffer.
Luke Hoersten <luke@hoersten.org>
parents:
85
diff
changeset
|
121 |
(ibuffer-remove-duplicates (remq nil (mapcar 'buffer-mode (buffer-list))))))) |
5e8b9d224e3e
Created dynamic major mode grouping for ibuffer.
Luke Hoersten <luke@hoersten.org>
parents:
85
diff
changeset
|
122 |
(mapcar 'mode-group (buffer-modes)))) |
5e8b9d224e3e
Created dynamic major mode grouping for ibuffer.
Luke Hoersten <luke@hoersten.org>
parents:
85
diff
changeset
|
123 |
|
5e8b9d224e3e
Created dynamic major mode grouping for ibuffer.
Luke Hoersten <luke@hoersten.org>
parents:
85
diff
changeset
|
124 |
(defun ibuffer-major-mode-group-hook () |
5e8b9d224e3e
Created dynamic major mode grouping for ibuffer.
Luke Hoersten <luke@hoersten.org>
parents:
85
diff
changeset
|
125 |
(interactive) |
5e8b9d224e3e
Created dynamic major mode grouping for ibuffer.
Luke Hoersten <luke@hoersten.org>
parents:
85
diff
changeset
|
126 |
(setq ibuffer-filter-groups (ibuffer-generate-filter-groups-by-major-mode)) |
5e8b9d224e3e
Created dynamic major mode grouping for ibuffer.
Luke Hoersten <luke@hoersten.org>
parents:
85
diff
changeset
|
127 |
(ibuffer-update nil t) |
5e8b9d224e3e
Created dynamic major mode grouping for ibuffer.
Luke Hoersten <luke@hoersten.org>
parents:
85
diff
changeset
|
128 |
(message "ibuffer-major-mode: groups set")) |
5e8b9d224e3e
Created dynamic major mode grouping for ibuffer.
Luke Hoersten <luke@hoersten.org>
parents:
85
diff
changeset
|
129 |
|
5e8b9d224e3e
Created dynamic major mode grouping for ibuffer.
Luke Hoersten <luke@hoersten.org>
parents:
85
diff
changeset
|
130 |
(setq-default ibuffer-show-empty-filter-groups nil) |
5e8b9d224e3e
Created dynamic major mode grouping for ibuffer.
Luke Hoersten <luke@hoersten.org>
parents:
85
diff
changeset
|
131 |
(add-hook 'ibuffer-hook (lambda () (ibuffer-major-mode-group-hook))) |
73
8167de2d2daa
Lots of random changes. Stopped using Chris Done's haskell-flycheck.
Luke Hoersten <Luke@Hoersten.org>
parents:
72
diff
changeset
|
132 |
|
78
7d7662fcc8d1
Started using shm and paredit.
Luke Hoersten <Luke@Hoersten.org>
parents:
77
diff
changeset
|
133 |
|
7d7662fcc8d1
Started using shm and paredit.
Luke Hoersten <Luke@Hoersten.org>
parents:
77
diff
changeset
|
134 |
;;; shell |
75 | 135 |
(global-set-key (kbd "C-c s") 'eshell) ; start shell |
77 | 136 |
(exec-path-from-shell-copy-env "PYTHONPATH") |
73
8167de2d2daa
Lots of random changes. Stopped using Chris Done's haskell-flycheck.
Luke Hoersten <Luke@Hoersten.org>
parents:
72
diff
changeset
|
137 |
(exec-path-from-shell-initialize) |
8167de2d2daa
Lots of random changes. Stopped using Chris Done's haskell-flycheck.
Luke Hoersten <Luke@Hoersten.org>
parents:
72
diff
changeset
|
138 |
(eshell) |
101 | 139 |
(setq tramp-default-method "ssh") |
100 | 140 |
(add-hook 'eshell-mode-hook |
141 |
(lambda () |
|
142 |
(setenv "TERM" "emacs") |
|
143 |
(setenv "PAGER" "cat"))) |
|
58
c25a7ccd237a
Stabalized new packages and modes.
Luke Hoersten <Luke@Hoersten.org>
parents:
57
diff
changeset
|
144 |
|
77 | 145 |
;;; ido / smex / completion |
82
12cf67bc486c
Added paredit, flx-ido and projectile.
Luke Hoersten <luke@hoersten.org>
parents:
78
diff
changeset
|
146 |
(setq-default |
12cf67bc486c
Added paredit, flx-ido and projectile.
Luke Hoersten <luke@hoersten.org>
parents:
78
diff
changeset
|
147 |
ido-enable-flex-matching t ; fuzzy matching for ido mode |
12cf67bc486c
Added paredit, flx-ido and projectile.
Luke Hoersten <luke@hoersten.org>
parents:
78
diff
changeset
|
148 |
ido-create-new-buffer 'always ; create new buffer without prompt |
12cf67bc486c
Added paredit, flx-ido and projectile.
Luke Hoersten <luke@hoersten.org>
parents:
78
diff
changeset
|
149 |
ido-max-window-height 1 ; max ido window height |
12cf67bc486c
Added paredit, flx-ido and projectile.
Luke Hoersten <luke@hoersten.org>
parents:
78
diff
changeset
|
150 |
ido-everywhere t ; use ido where possible |
12cf67bc486c
Added paredit, flx-ido and projectile.
Luke Hoersten <luke@hoersten.org>
parents:
78
diff
changeset
|
151 |
ido-use-faces nil) |
12cf67bc486c
Added paredit, flx-ido and projectile.
Luke Hoersten <luke@hoersten.org>
parents:
78
diff
changeset
|
152 |
(ido-mode t) ; file/buffer selector |
12cf67bc486c
Added paredit, flx-ido and projectile.
Luke Hoersten <luke@hoersten.org>
parents:
78
diff
changeset
|
153 |
(flx-ido-mode t) |
76
af643427e1be
Added ido-at-point completion.
Luke Hoersten <Luke@Hoersten.org>
parents:
75
diff
changeset
|
154 |
(global-set-key (kbd "M-/") 'completion-at-point) |
77 | 155 |
(global-set-key (kbd "M-x") 'smex) |
156 |
(global-set-key (kbd "M-X") 'smex-major-mode-commands) |
|
76
af643427e1be
Added ido-at-point completion.
Luke Hoersten <Luke@Hoersten.org>
parents:
75
diff
changeset
|
157 |
|
78
7d7662fcc8d1
Started using shm and paredit.
Luke Hoersten <Luke@Hoersten.org>
parents:
77
diff
changeset
|
158 |
|
7d7662fcc8d1
Started using shm and paredit.
Luke Hoersten <Luke@Hoersten.org>
parents:
77
diff
changeset
|
159 |
;;; emacs-lisp-mode |
85
0b91f7fe5a89
Reorganized global modes a bit. Fixed multi-frame font changes.
Luke Hoersten <luke@hoersten.org>
parents:
84
diff
changeset
|
160 |
(add-hook 'emacs-lisp-mode-hook 'enable-paredit-mode) |
77 | 161 |
|
162 |
||
163 |
;;; company-mode |
|
85
0b91f7fe5a89
Reorganized global modes a bit. Fixed multi-frame font changes.
Luke Hoersten <luke@hoersten.org>
parents:
84
diff
changeset
|
164 |
(global-company-mode t) |
77 | 165 |
(global-set-key (kbd "M-/") 'company-complete) |
78
7d7662fcc8d1
Started using shm and paredit.
Luke Hoersten <Luke@Hoersten.org>
parents:
77
diff
changeset
|
166 |
(setq-default |
7d7662fcc8d1
Started using shm and paredit.
Luke Hoersten <Luke@Hoersten.org>
parents:
77
diff
changeset
|
167 |
company-idle-delay nil |
7d7662fcc8d1
Started using shm and paredit.
Luke Hoersten <Luke@Hoersten.org>
parents:
77
diff
changeset
|
168 |
company-minimum-prefix-length 2 |
7d7662fcc8d1
Started using shm and paredit.
Luke Hoersten <Luke@Hoersten.org>
parents:
77
diff
changeset
|
169 |
company-selection-wrap-around t |
7d7662fcc8d1
Started using shm and paredit.
Luke Hoersten <Luke@Hoersten.org>
parents:
77
diff
changeset
|
170 |
company-show-numbers t |
7d7662fcc8d1
Started using shm and paredit.
Luke Hoersten <Luke@Hoersten.org>
parents:
77
diff
changeset
|
171 |
company-tooltip-align-annotations t) |
7d7662fcc8d1
Started using shm and paredit.
Luke Hoersten <Luke@Hoersten.org>
parents:
77
diff
changeset
|
172 |
|
59
f346d7591eac
Removed more unused init code.
Luke Hoersten <Luke@Hoersten.org>
parents:
58
diff
changeset
|
173 |
|
85
0b91f7fe5a89
Reorganized global modes a bit. Fixed multi-frame font changes.
Luke Hoersten <luke@hoersten.org>
parents:
84
diff
changeset
|
174 |
;;; flycheck-mode |
0b91f7fe5a89
Reorganized global modes a bit. Fixed multi-frame font changes.
Luke Hoersten <luke@hoersten.org>
parents:
84
diff
changeset
|
175 |
(global-flycheck-mode t) |
0b91f7fe5a89
Reorganized global modes a bit. Fixed multi-frame font changes.
Luke Hoersten <luke@hoersten.org>
parents:
84
diff
changeset
|
176 |
|
0b91f7fe5a89
Reorganized global modes a bit. Fixed multi-frame font changes.
Luke Hoersten <luke@hoersten.org>
parents:
84
diff
changeset
|
177 |
|
55
d4adcd3d5ef9
Updated to emacs24 with package management and load-theme
Luke Hoersten <Luke@Hoersten.org>
parents:
54
diff
changeset
|
178 |
;;; uniquify |
75 | 179 |
(require 'uniquify) ; unique buffer names with dirs |
55
d4adcd3d5ef9
Updated to emacs24 with package management and load-theme
Luke Hoersten <Luke@Hoersten.org>
parents:
54
diff
changeset
|
180 |
(setq |
d4adcd3d5ef9
Updated to emacs24 with package management and load-theme
Luke Hoersten <Luke@Hoersten.org>
parents:
54
diff
changeset
|
181 |
uniquify-buffer-name-style 'post-forward |
d4adcd3d5ef9
Updated to emacs24 with package management and load-theme
Luke Hoersten <Luke@Hoersten.org>
parents:
54
diff
changeset
|
182 |
uniquify-separator ":") |
d4adcd3d5ef9
Updated to emacs24 with package management and load-theme
Luke Hoersten <Luke@Hoersten.org>
parents:
54
diff
changeset
|
183 |
|
78
7d7662fcc8d1
Started using shm and paredit.
Luke Hoersten <Luke@Hoersten.org>
parents:
77
diff
changeset
|
184 |
|
55
d4adcd3d5ef9
Updated to emacs24 with package management and load-theme
Luke Hoersten <Luke@Hoersten.org>
parents:
54
diff
changeset
|
185 |
;;; color-theme |
d4adcd3d5ef9
Updated to emacs24 with package management and load-theme
Luke Hoersten <Luke@Hoersten.org>
parents:
54
diff
changeset
|
186 |
(setq-default |
d4adcd3d5ef9
Updated to emacs24 with package management and load-theme
Luke Hoersten <Luke@Hoersten.org>
parents:
54
diff
changeset
|
187 |
custom-safe-themes |
d4adcd3d5ef9
Updated to emacs24 with package management and load-theme
Luke Hoersten <Luke@Hoersten.org>
parents:
54
diff
changeset
|
188 |
'("8aebf25556399b58091e533e455dd50a6a9cba958cc4ebb0aab175863c25b9a4" |
d4adcd3d5ef9
Updated to emacs24 with package management and load-theme
Luke Hoersten <Luke@Hoersten.org>
parents:
54
diff
changeset
|
189 |
"d677ef584c6dfc0697901a44b885cc18e206f05114c8a3b7fde674fce6180879" default)) |
85
0b91f7fe5a89
Reorganized global modes a bit. Fixed multi-frame font changes.
Luke Hoersten <luke@hoersten.org>
parents:
84
diff
changeset
|
190 |
(when window-system (load-theme 'solarized-light)) |
42 | 191 |
|
78
7d7662fcc8d1
Started using shm and paredit.
Luke Hoersten <Luke@Hoersten.org>
parents:
77
diff
changeset
|
192 |
|
82
12cf67bc486c
Added paredit, flx-ido and projectile.
Luke Hoersten <luke@hoersten.org>
parents:
78
diff
changeset
|
193 |
;;; show-paren-mode - needs to be loaded after theme |
12cf67bc486c
Added paredit, flx-ido and projectile.
Luke Hoersten <luke@hoersten.org>
parents:
78
diff
changeset
|
194 |
(setq-default |
12cf67bc486c
Added paredit, flx-ido and projectile.
Luke Hoersten <luke@hoersten.org>
parents:
78
diff
changeset
|
195 |
show-paren-style 'expression |
12cf67bc486c
Added paredit, flx-ido and projectile.
Luke Hoersten <luke@hoersten.org>
parents:
78
diff
changeset
|
196 |
show-paren-delay 0) |
12cf67bc486c
Added paredit, flx-ido and projectile.
Luke Hoersten <luke@hoersten.org>
parents:
78
diff
changeset
|
197 |
(set-face-attribute |
12cf67bc486c
Added paredit, flx-ido and projectile.
Luke Hoersten <luke@hoersten.org>
parents:
78
diff
changeset
|
198 |
'show-paren-match nil |
12cf67bc486c
Added paredit, flx-ido and projectile.
Luke Hoersten <luke@hoersten.org>
parents:
78
diff
changeset
|
199 |
:background (face-background 'highlight) |
12cf67bc486c
Added paredit, flx-ido and projectile.
Luke Hoersten <luke@hoersten.org>
parents:
78
diff
changeset
|
200 |
:foreground (face-foreground 'highlight)) |
12cf67bc486c
Added paredit, flx-ido and projectile.
Luke Hoersten <luke@hoersten.org>
parents:
78
diff
changeset
|
201 |
(show-paren-mode t) |
12cf67bc486c
Added paredit, flx-ido and projectile.
Luke Hoersten <luke@hoersten.org>
parents:
78
diff
changeset
|
202 |
|
12cf67bc486c
Added paredit, flx-ido and projectile.
Luke Hoersten <luke@hoersten.org>
parents:
78
diff
changeset
|
203 |
|
31
27930e0310d6
Reorganized a ton. Split into 3 main sections: General, Modes, and Requires.
Luke Hoersten <Luke@Hoersten.org>
parents:
30
diff
changeset
|
204 |
;;; yasnippets |
94 | 205 |
(with-eval-after-load 'yasnippet |
206 |
(setq yas-snippet-dirs (remq 'yas-installed-snippets-dir yas-snippet-dirs))) |
|
207 |
(setq-default yas-prompt-functions '(yas-ido-prompt yas-dropdown-prompt)) ; use ido for multiple snippets |
|
208 |
(yas-global-mode t) |
|
31
27930e0310d6
Reorganized a ton. Split into 3 main sections: General, Modes, and Requires.
Luke Hoersten <Luke@Hoersten.org>
parents:
30
diff
changeset
|
209 |
|
71
b5976ed7311a
Big updates to haskell-mode stuff.
Luke Hoersten <Luke@Hoersten.org>
parents:
70
diff
changeset
|
210 |
|
b5976ed7311a
Big updates to haskell-mode stuff.
Luke Hoersten <Luke@Hoersten.org>
parents:
70
diff
changeset
|
211 |
;;; markdown-mode |
b5976ed7311a
Big updates to haskell-mode stuff.
Luke Hoersten <Luke@Hoersten.org>
parents:
70
diff
changeset
|
212 |
(add-hook 'markdown-mode-hook 'flyspell-mode) |
101 | 213 |
(setq-default markdown-command "pandoc -f gfm") |
71
b5976ed7311a
Big updates to haskell-mode stuff.
Luke Hoersten <Luke@Hoersten.org>
parents:
70
diff
changeset
|
214 |
|
55
d4adcd3d5ef9
Updated to emacs24 with package management and load-theme
Luke Hoersten <Luke@Hoersten.org>
parents:
54
diff
changeset
|
215 |
|
58
c25a7ccd237a
Stabalized new packages and modes.
Luke Hoersten <Luke@Hoersten.org>
parents:
57
diff
changeset
|
216 |
;;; html-mode |
53 | 217 |
(add-to-list 'auto-mode-alist '("\\.tpl\\'" . html-mode)) |
85
0b91f7fe5a89
Reorganized global modes a bit. Fixed multi-frame font changes.
Luke Hoersten <luke@hoersten.org>
parents:
84
diff
changeset
|
218 |
(add-hook 'html-mode-hook 'zencoding-mode) |
58
c25a7ccd237a
Stabalized new packages and modes.
Luke Hoersten <Luke@Hoersten.org>
parents:
57
diff
changeset
|
219 |
|
78
7d7662fcc8d1
Started using shm and paredit.
Luke Hoersten <Luke@Hoersten.org>
parents:
77
diff
changeset
|
220 |
|
85
0b91f7fe5a89
Reorganized global modes a bit. Fixed multi-frame font changes.
Luke Hoersten <luke@hoersten.org>
parents:
84
diff
changeset
|
221 |
;;; color-modes map |
37
3c51085957be
Added rainbow-delimiter (multi-colored parens) mode and updated twilight color theme.
Luke Hoersten <Luke@Hoersten.org>
parents:
36
diff
changeset
|
222 |
(mapc |
59
f346d7591eac
Removed more unused init code.
Luke Hoersten <Luke@Hoersten.org>
parents:
58
diff
changeset
|
223 |
(lambda (x) |
60
8beb028f936c
Fixed a bug with the haskell-mode-hook
Luke Hoersten <Luke@Hoersten.org>
parents:
59
diff
changeset
|
224 |
(add-hook x |
65 | 225 |
(lambda () |
226 |
(linum-mode t) |
|
73
8167de2d2daa
Lots of random changes. Stopped using Chris Done's haskell-flycheck.
Luke Hoersten <Luke@Hoersten.org>
parents:
72
diff
changeset
|
227 |
(rainbow-delimiters-mode t)))) |
37
3c51085957be
Added rainbow-delimiter (multi-colored parens) mode and updated twilight color theme.
Luke Hoersten <Luke@Hoersten.org>
parents:
36
diff
changeset
|
228 |
'(text-mode-hook |
3c51085957be
Added rainbow-delimiter (multi-colored parens) mode and updated twilight color theme.
Luke Hoersten <Luke@Hoersten.org>
parents:
36
diff
changeset
|
229 |
c-mode-common-hook |
3c51085957be
Added rainbow-delimiter (multi-colored parens) mode and updated twilight color theme.
Luke Hoersten <Luke@Hoersten.org>
parents:
36
diff
changeset
|
230 |
python-mode-hook |
3c51085957be
Added rainbow-delimiter (multi-colored parens) mode and updated twilight color theme.
Luke Hoersten <Luke@Hoersten.org>
parents:
36
diff
changeset
|
231 |
haskell-mode-hook |
58
c25a7ccd237a
Stabalized new packages and modes.
Luke Hoersten <Luke@Hoersten.org>
parents:
57
diff
changeset
|
232 |
js2-mode-hook |
c25a7ccd237a
Stabalized new packages and modes.
Luke Hoersten <Luke@Hoersten.org>
parents:
57
diff
changeset
|
233 |
html-mode-hook |
c25a7ccd237a
Stabalized new packages and modes.
Luke Hoersten <Luke@Hoersten.org>
parents:
57
diff
changeset
|
234 |
css-mode-hook |
86 | 235 |
sass-mode-hook |
50 | 236 |
clojure-mode-hook |
77 | 237 |
emacs-lisp-mode-hook |
238 |
conf-mode-hook |
|
100 | 239 |
yaml-mode-hook |
240 |
sql-mode-hook)) |
|
55
d4adcd3d5ef9
Updated to emacs24 with package management and load-theme
Luke Hoersten <Luke@Hoersten.org>
parents:
54
diff
changeset
|
241 |
|
78
7d7662fcc8d1
Started using shm and paredit.
Luke Hoersten <Luke@Hoersten.org>
parents:
77
diff
changeset
|
242 |
|
71
b5976ed7311a
Big updates to haskell-mode stuff.
Luke Hoersten <Luke@Hoersten.org>
parents:
70
diff
changeset
|
243 |
;;; expand-region |
72 | 244 |
(global-set-key (kbd "C-=") 'er/expand-region) |
69
b3baf25406f8
Messing with new haskell mode.
Luke Hoersten <Luke@Hoersten.org>
parents:
68
diff
changeset
|
245 |
|
78
7d7662fcc8d1
Started using shm and paredit.
Luke Hoersten <Luke@Hoersten.org>
parents:
77
diff
changeset
|
246 |
|
71
b5976ed7311a
Big updates to haskell-mode stuff.
Luke Hoersten <Luke@Hoersten.org>
parents:
70
diff
changeset
|
247 |
;;; move-text |
b5976ed7311a
Big updates to haskell-mode stuff.
Luke Hoersten <Luke@Hoersten.org>
parents:
70
diff
changeset
|
248 |
(global-set-key (kbd "M-p") 'move-text-up) |
b5976ed7311a
Big updates to haskell-mode stuff.
Luke Hoersten <Luke@Hoersten.org>
parents:
70
diff
changeset
|
249 |
(global-set-key (kbd "M-n") 'move-text-down) |
59
f346d7591eac
Removed more unused init code.
Luke Hoersten <Luke@Hoersten.org>
parents:
58
diff
changeset
|
250 |
|
78
7d7662fcc8d1
Started using shm and paredit.
Luke Hoersten <Luke@Hoersten.org>
parents:
77
diff
changeset
|
251 |
|
59
f346d7591eac
Removed more unused init code.
Luke Hoersten <Luke@Hoersten.org>
parents:
58
diff
changeset
|
252 |
;;; visual-regexp |
f346d7591eac
Removed more unused init code.
Luke Hoersten <Luke@Hoersten.org>
parents:
58
diff
changeset
|
253 |
(global-set-key (kbd "C-M-%") 'vr/query-replace) |
f346d7591eac
Removed more unused init code.
Luke Hoersten <Luke@Hoersten.org>
parents:
58
diff
changeset
|
254 |
(global-set-key (kbd "M-%") 'vr/replace) |
103 | 255 |
|
256 |
(provide 'init) |
|
257 |
;;; init.el ends here |