-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathinit.el
More file actions
225 lines (186 loc) · 6.09 KB
/
init.el
File metadata and controls
225 lines (186 loc) · 6.09 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
;; /su: or /sudo: on remote hosts
;; You can also use this syntax to sudo/su to root (or of course any other user) on a remote host:
;; C-xC-f /ssh:you@remotehost|sudo:remotehost:/path/to/file RET
;; http://stackoverflow.com/questions/2177687/open-file-via-ssh-and-sudo-with-emacs
;; Use a hook so the message doesn't get clobbered by other messages.
(add-hook 'emacs-startup-hook
(lambda ()
(message "Emacs ready in %s with %d garbage collections."
(format "%.2f seconds"
(float-time
(time-subtract after-init-time before-init-time)))
gcs-done)))
;;
;; X? no tool-bar no scroll-bar
;;
(if (display-graphic-p)
(progn
(if (fboundp 'tool-bar-mode) (tool-bar-mode -1))
(if (fboundp 'scroll-bar-mode) (scroll-bar-mode -1))
(if (fboundp 'menu-bar-mode) (menu-bar-mode -1))
)
nil)
;;
;; Emacs Lisp Path
;;
(add-to-list 'load-path "~/.emacs.d/lisp")
;;
;; Melpa
;;
(require 'package)
(package-initialize)
(add-to-list 'package-archives
'("melpa" . "https://melpa.org/packages/") t)
(add-to-list 'package-archives
'("org" . "https://orgmode.org/elpa/") t)
;;
;; OS-adjustments
;;
(if (eq system-type 'windows-nt)
(progn
;; http://stackoverflow.com/questions/2007329/emacs-23-1-50-1-hangs-ramdomly-for-6-8-seconds-on-windows-xp
;; try to improve slow performance on windows.
(setq w32-get-true-file-attributes nil)
;; Unicode Slow in Windows: https://emacs.stackexchange.com/questions/33510/unicode-txt-slowness
(setq inhibit-compacting-font-caches t))
nil )
;;
;; X or console?
;;
(if (display-graphic-p)
(progn
;; (set-face-attribute 'default nil :font "Bitstream Vera Sans Mono" :height 95)
;; (set-face-attribute 'default nil :font "Ubuntu Mono" :height 120)
;; (set-face-attribute 'default nil :font "Terminus" :height 120)
;; (set-face-attribute 'default nil :font "Consolas" :height 100)
(set-face-attribute 'default nil :font "Menlo" :height 100)
;; Color Themes
(load-theme 'monokai t)
;; (load-theme 'sanityinc-tomorrow-eighties t)
;; (load-theme 'cyberpunkaxxl t)
;; (load-theme 'cyberpunk t)
;; (load-theme 'zenburn t)
;; (load-theme 'solarized-dark t)
;; (load-theme 'birds-of-paradise-plus t)
;; (setq-default cursor-type 'bar)
;; (setq-default cursor-type 'box)
(global-unset-key (kbd "C-z"))
) ; progn
nil )
;;
;; Load external files
;;
(setq custom-file "~/.emacs.d/custom.el")
(load custom-file)
(load "~/.emacs.d/lisp/basic.el")
(load "~/.emacs.d/lisp/modes.el")
(load "~/.emacs.d/lisp/functions.el")
(load "~/.emacs.d/lisp/keys.el")
(load "~/.emacs.d/lisp/windows.el")
;; (load "~/.emacs.d/lisp/mymu4e.el")
;; (load "~/.emacs.d/lisp/temp_js.el")
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;
;; SMEX
;;
;; (smex-initialize)
;;
;; yaml mode
;;
;; (require 'yaml-mode)
;;
;; simple wiki mode
;;
;; (require 'simple-wiki)
;;
;; Emacs Server
;;
(server-start)
(unless (server-running-p)
(server-start))
;;
;; AUTO-COMPLETE
;;
;; (require 'auto-complete-config)
;; (add-to-list 'ac-dictionary-directories "~/.emacs.d/ac-dict")
;; (ac-config-default)
;; (global-auto-complete-mode t)
;;
;; company mode
;;
(global-company-mode t)
(setq company-idle-delay 0.2)
(setq company-selection-wrap-around t)
;; remove annoying blinking
;; (setq company-echo-delay 0)
;; start autocompletion only after typing
;; (setq company-begin-commands '(self-insert-command))
;; Do not convert to lowercase
;; (setq company-dabbrev-downcase nil)
;;
;; saveplace
;; Remember the cursor position of files when reopening them
;;
;; (setq save-place-file "~/.emacs.d/saveplace")
;; (setq-default save-place t)
;; (require 'saveplace)
;;
;; HELM
;;
;; (require 'helm-config)
;; (setq helm-candidate-number-limit 100)
;; ;; From https://gist.github.com/antifuchs/9238468
;; (setq helm-idle-delay 0.0 ; update fast sources immediately (doesn't).
;; helm-input-idle-delay 0.01 ; this actually updates things
;; ; reeeelatively quickly.
;; helm-quick-update ;TODO:
;; ;; helm-M-x-requires-pattern nil
;; ;; helm-ff-skip-boring-files t
;; )
;; (helm-mode 1)
;; (global-set-key (kbd "C-c h") 'helm-mini)
;; (global-set-key (kbd "C-h a") 'helm-apropos)
;; (global-set-key (kbd "C-x C-b") 'helm-buffers-list)
;; (global-set-key (kbd "C-x b") 'helm-buffers-list)
;; (global-set-key (kbd "M-y") 'helm-show-kill-ring)
;; (global-set-key (kbd "M-x") 'helm-M-x)
;; (global-set-key (kbd "C-x c o") 'helm-occur)
;; (global-set-key (kbd "C-x c s") 'helm-swoop)
;; (global-set-key (kbd "C-x c b") 'my/helm-do-grep-book-notes)
;; (global-set-key (kbd "C-x c SPC") 'helm-all-mark-rings)
;; (ido-mode -1) ;; Turn off ido mode in case I enabled it accidentally
;; ,----
;; | magit
;; `----
;; (global-set-key (kbd "C-x g") 'magit-status)
;; ,----
;; | Open HTML with Firefox as default
;; `----
;; (setq browse-url-firefox-program "C:/Program Files (x86)/Mozilla Firefox/firefox.exe")
;; (setq browse-url-generic-program "vivaldi"
;; browse-url-browser-function 'browse-url-generic)
;; ,----
;; | org ox reveal.js
;; `----
;; (setq org-reveal-root "file:///d:/reveal.js")
;;
;; EMMS
;;
;; (emms-standard)
;; (emms-default-players)
;; (setq emms-source-file-default-directory "~/Musik/mp3")
(setq url-proxy-services '(("no_proxy" . "telekom\\.de")
("http" . "specialinternetaccess-lb.telekom.de:8080")
("https" . "specialinternetaccess-lb.telekom.de:8080")))
;; (require 'confluence)
;; (setq confluence-url "https://seu30.gdc-dmst01.t-systems.com/confluence/rpc/xmlrpc")
;; Org Agenda
(setq org-todo-keywords
'((sequence "TODO" "|" "IN PROGRESS" "|" "DONE" "CANCELLED" "DELEGATED")))
(setq org-todo-keyword-faces
'(("IN PROGRESS" . "yellow")))
(add-hook 'after-init-hook 'org-agenda-list)
;; PLANTUML Mode
;; (defcustom plantuml-jar-path
(setq plantuml-default-exec-mode 'jar)
(setq plantuml-jar-path "~/../bin/plantuml/plantuml.jar")