Remove smooth-scrolling because it was useless
- Author
- Maarten Vangeneugden
- Date
- July 24, 2024, 12:46 p.m.
- Hash
- d93eb8152afaa2ecd6b361c6b887a0531d272e4f
- Parent
- 48eef49dff696152174234b34ea66a791f85ac48
- Modified file
- init.el
init.el ¶
4 additions and 4 deletions.
View changes Hide changes
1 |
1 |
;; Copyright © 2018-2022 Maarten Vangeneugden |
2 |
2 |
;; Author: Maarten Vangeneugden <contact_me@maartenv.be> |
3 |
3 |
;; URL: https://maartenv.be |
4 |
4 |
;; |
5 |
5 |
;; Welcome to Ghent Emacs. |
6 |
6 |
;; |
7 |
7 |
;; This is the configuration file for Ghent Emacs, a GNU Emacs derivative |
8 |
8 |
;; developed in the city of Ghent, Belgium, by a student of Engineering |
9 |
9 |
;; Informatics at Ghent University. |
10 |
10 |
;; |
11 |
11 |
;; License: GPLv3+ |
12 |
12 |
|
13 |
13 |
;; USAGE: |
14 |
14 |
;; This configuration file uses the use-package declaration, that means the |
15 |
15 |
;; settings are a bit different from what you'd normally do in a GNU Emacs |
16 |
16 |
;; init.el file. Consult https://github.com/jwiegley/use-package for info on how |
17 |
17 |
;; to correctly write package configuration. |
18 |
18 |
|
19 |
19 |
(eval-when-compile |
20 |
20 |
(require 'use-package)) |
21 |
21 |
;(require 'diminish) ;; if you use :diminish |
22 |
22 |
(require 'bind-key) ;; if you use any :bind variant |
23 |
23 |
|
24 |
24 |
(custom-set-variables |
25 |
25 |
;; custom-set-variables was added by Custom. |
26 |
26 |
;; If you edit it by hand, you could mess it up, so be careful. |
27 |
27 |
;; Your init file should contain only one such instance. |
28 |
28 |
;; If there is more than one, they won't work right. |
29 |
29 |
'(custom-safe-themes |
30 |
30 |
'("763bf89898a06b03f7b65fbc29857a1c292e4350246093702fdbd6c4e46e2cf0" "78e6be576f4a526d212d5f9a8798e5706990216e9be10174e3f3b015b8662e27" "d9646b131c4aa37f01f909fbdd5a9099389518eb68f25277ed19ba99adeb7279" "8b58ef2d23b6d164988a607ee153fd2fa35ee33efc394281b1028c2797ddeebb" "f9aede508e587fe21bcfc0a85e1ec7d27312d9587e686a6f5afdbb0d220eab50" "83ae405e25a0a81f2840bfe5daf481f74df0ddb687f317b5e005aa61261126e9" "c433c87bd4b64b8ba9890e8ed64597ea0f8eb0396f4c9a9e01bd20a04d15d358" "a24c5b3c12d147da6cef80938dca1223b7c7f70f2f382b26308eba014dc4833a" "732b807b0543855541743429c9979ebfb363e27ec91e82f463c91e68c772f6e3" "a2cde79e4cc8dc9a03e7d9a42fabf8928720d420034b66aecc5b665bbf05d4e9" "8aebf25556399b58091e533e455dd50a6a9cba958cc4ebb0aab175863c25b9a4" "bd7b7c5df1174796deefce5debc2d976b264585d51852c962362be83932873d9" default)) |
31 |
31 |
'(inhibit-startup-screen t) |
32 |
32 |
'(package-selected-packages |
33 |
33 |
'(company-fuzzy web-mode use-package undo-tree srefactor spacemacs-theme spaceline solarized-theme smooth-scrolling rainbow-delimiters pretty-mode page-break-lines monokai-theme helm general evil dashboard dante company-ycmd company-flx company-anaconda clang-format auto-package-update auctex a)) |
34 |
- | '(spaceline-inflation 1 t nil "Customized with use-package spaceline") |
+ |
34 |
'(spaceline-inflation 1 t nil "Customized with use-package spaceline") |
35 |
35 |
'(spaceline-toggle-buffer-size-off nil t nil "Customized with use-package spaceline")) |
36 |
36 |
;(custom-set-faces |
37 |
37 |
;; custom-set-faces was added by Custom. |
38 |
38 |
;; If you edit it by hand, you could mess it up, so be careful. |
39 |
39 |
;; Your init file should contain only one such instance. |
40 |
40 |
;; If there is more than one, they won't work right. |
41 |
41 |
;'(default ((((class color) (min-colors 89)) (:foreground "#ffffff" :background "#263238"))))) |
42 |
42 |
|
43 |
43 |
;; To get rid of those FUCKING ANNOYING BACKUP FILES FUCKING HELL DUDE |
44 |
44 |
(setq backup-directory-alist '(("." . "~/.emacs.d/backup")) |
45 |
45 |
backup-by-copying t ; Don't delink hardlinks |
46 |
46 |
version-control t ; Use version numbers on backups |
47 |
47 |
delete-old-versions t ; Automatically delete excess backups |
48 |
48 |
kept-new-versions 20 ; how many of the newest versions to keep |
49 |
49 |
kept-old-versions 5 ; and how many of the old |
50 |
50 |
) |
51 |
51 |
;; And yes I copied it from SO, suck it: https://stackoverflow.com/questions/2680389/how-to-remove-all-files-ending-with-made-by-emacs |
52 |
52 |
|
53 |
53 |
;; Disables the use of tabs, replaces them with spaces |
54 |
54 |
(setq-default indent-tabs-mode nil) |
55 |
55 |
|
56 |
56 |
;; Activate UTF-8 throughout Ghent Emacs |
57 |
57 |
(prefer-coding-system 'utf-8) |
58 |
58 |
(set-default-coding-systems 'utf-8) |
59 |
59 |
(set-terminal-coding-system 'utf-8) |
60 |
60 |
(set-keyboard-coding-system 'utf-8) |
61 |
61 |
(setq x-select-request-type '(UTF8_STRING COMPOUND_TEXT TEXT STRING)) |
62 |
62 |
|
63 |
63 |
;; Line numbering config |
64 |
64 |
(global-display-line-numbers-mode) |
65 |
65 |
(setq display-line-numbers-mode t) |
66 |
66 |
(setq display-line-numbers-widen t) |
67 |
67 |
(setq display-line-numbers-type 'relative) |
68 |
68 |
(setq display-line-numbers-current-absolute t) |
69 |
69 |
|
70 |
70 |
(setq mouse-wheel-scroll-amount '(1 ((shift) . 1))) |
71 |
71 |
(setq scroll-step 1) |
72 |
72 |
(setq scroll-margin 10) ;; Keeps 10 lines above and down always visible if still left |
73 |
73 |
|
74 |
74 |
;; Enable line breaks in all modes at column 80 |
75 |
75 |
(setq-default auto-fill-function 'do-auto-fill) |
76 |
76 |
(setq-default fill-column 80) |
77 |
77 |
|
78 |
78 |
(setq ring-bell-function 'ignore) ;; Disables the FUCKING ANNOYING BEEPS HOLY SHIT |
79 |
79 |
|
80 |
80 |
;; Setup packages |
81 |
81 |
;(package-initialize) |
82 |
82 |
(require 'package) |
83 |
83 |
(setq package-enable-at-startup nil) |
84 |
84 |
(add-to-list 'package-archives '("org" . "https://orgmode.org/elpa/")) |
85 |
85 |
(add-to-list 'package-archives '("melpa" . "http://melpa.org/packages/")) |
86 |
86 |
(unless (package-installed-p 'use-package) |
87 |
87 |
(package-refresh-contents) |
88 |
88 |
(package-install 'use-package)) |
89 |
89 |
|
90 |
90 |
|
91 |
91 |
|
92 |
92 |
|
93 |
93 |
;; Next two lines allow foregoing :ensure t on all packages |
94 |
94 |
;; :ensure t simply makes sure that, if a package isn't installed on this |
95 |
95 |
;; machine, it's automatically fetched and installed. |
96 |
96 |
;; This doesn't keep packages up-to-date, cfr. auto-package-update for that |
97 |
97 |
(require 'use-package-ensure) |
98 |
98 |
(setq use-package-always-ensure t) |
99 |
99 |
|
100 |
100 |
;; Package for automatic updating of all the other packages |
101 |
101 |
(use-package auto-package-update |
102 |
102 |
:config |
103 |
103 |
(setq auto-package-update-delete-old-versions t) |
104 |
104 |
(setq auto-package-update-hide-results t) |
105 |
105 |
(auto-package-update-maybe)) |
106 |
106 |
|
107 |
107 |
;; Easier keybindings so we can do more lazy loading |
108 |
108 |
(use-package general |
109 |
109 |
:config |
110 |
110 |
(general-create-definer my-leader-def |
111 |
111 |
;; :prefix my-leader |
112 |
112 |
:prefix "SPC") |
113 |
113 |
(general-create-definer local-leader-def |
114 |
114 |
;; :prefix local-leader |
115 |
115 |
:prefix ",")) |
116 |
116 |
|
117 |
117 |
(use-package dashboard |
118 |
118 |
:init |
119 |
119 |
(setq dashboard-banner-logo-title "") ; It's nicer to just not have a title text. |
120 |
120 |
(setq dashboard-startup-banner "~/ghent-emacs.png") |
121 |
121 |
:config |
122 |
122 |
(dashboard-setup-startup-hook)) |
123 |
123 |
|
124 |
124 |
;; AUCTeX configuration |
125 |
125 |
;; Partly inspired by https://piotr.is/2010/emacs-as-the-ultimate-latex-editor/ |
126 |
126 |
;;;;(use-package auctex |
127 |
127 |
;;:init |
128 |
128 |
;;(setq TeX-auto-save t) |
129 |
129 |
;;(setq TeX-parse-self t) |
130 |
130 |
;;(setq Tex-save-query nil) |
131 |
131 |
;;) |
132 |
132 |
|
133 |
133 |
;; Updates all packages automatically |
134 |
134 |
(use-package auto-package-update |
135 |
135 |
:config |
136 |
136 |
(setq auto-package-update-delete-old-versions t) |
137 |
137 |
(setq auto-package-update-hide-results t) |
138 |
138 |
(auto-package-update-maybe)) |
139 |
139 |
|
140 |
140 |
;; UI settings |
141 |
141 |
(tool-bar-mode -1) |
142 |
142 |
(menu-bar-mode -1) |
143 |
143 |
(toggle-scroll-bar -1) |
144 |
144 |
|
145 |
145 |
;; Tabs and width |
146 |
146 |
(setq-default tab-width 4) |
147 |
147 |
(setq-default c-basic-offset 4) |
148 |
148 |
|
149 |
149 |
(use-package spaceline |
150 |
150 |
:init |
151 |
151 |
(setq frame-char-height 35) |
152 |
152 |
(setq powerline-height 35) |
153 |
153 |
:custom |
154 |
154 |
(spaceline-toggle-buffer-size-off) |
155 |
155 |
;(setq powerline-height 21) |
156 |
156 |
(spaceline-inflation 1) |
157 |
157 |
(powerline-default-separator 'slant) |
158 |
158 |
:config |
159 |
159 |
(spaceline-spacemacs-theme) |
160 |
160 |
(setq spaceline-highlight-face-func 'spaceline-highlight-face-evil-state)) |
161 |
161 |
|
162 |
162 |
|
163 |
163 |
(use-package monokai-theme |
164 |
164 |
:config |
165 |
165 |
(load-theme 'monokai t) |
166 |
166 |
(setq monokai-variable-pitch-mode t)) |
167 |
167 |
;; When using solarized as theme, put in :config |
168 |
168 |
;; (setq x-underline-at-descent-line t) |
169 |
169 |
;; Which will block an ugly line being drawn trhough the modeline. |
170 |
170 |
|
171 |
171 |
;(add-hook 'org-mode-hook '(lambda () (setq fill-column 80))) |
172 |
172 |
;(add-hook 'org-mode-hook 'auto-fill-mode) |
173 |
173 |
;; (Programming) languages |
174 |
174 |
|
175 |
175 |
|
176 |
176 |
|
177 |
177 |
(use-package dante |
178 |
178 |
:after haskell-mode |
179 |
179 |
:commands 'dante-mode |
180 |
180 |
:init |
181 |
181 |
(add-hook 'haskell-mode-hook 'dante-mode) |
182 |
182 |
(add-hook 'haskell-mode-hook 'flycheck-mode)) |
183 |
183 |
|
184 |
184 |
|
185 |
185 |
;; HTML/CSS/Django |
186 |
186 |
(use-package web-mode |
187 |
187 |
:mode "\\.html?\\.djhtml\\'" |
188 |
188 |
:init |
189 |
189 |
(add-to-list 'auto-mode-alist '("\\.djhtml\\'" . web-mode)) |
190 |
190 |
(setq web-mode-markup-indent-offset 4) |
191 |
191 |
(setq web-mode-css-indent-offset 4) |
192 |
192 |
(setq web-mode-code-indent-offset 4) |
193 |
193 |
;(setq web-mode-engines-alist |
194 |
194 |
; '(("django" . "\\.html\\"))) ;; FIXME this doesn't work yet. IDK why. |
195 |
195 |
:custom ;; Next lines disable all the automatic completion stuff that I didn't explicitely ask for |
196 |
196 |
(web-mode-enable-auto-pairing nil) |
197 |
197 |
(web-mode-enable-auto-closing nil) |
198 |
198 |
(web-mode-enable-auto-expanding nil) |
199 |
199 |
(web-mode-enable-auto-opening nil) |
200 |
200 |
(web-mode-enable-auto-quoting nil)) |
201 |
201 |
|
202 |
202 |
|
203 |
203 |
;;(use-package ycmd-mode |
204 |
204 |
;;:ensure ycmd |
205 |
205 |
;;;:hook (after-init . global-ycmd-mode) |
206 |
206 |
;;:hook (haskell-mode elisp-mode python-mode c-mode c++-mode) ; Add the modes of the languages where YCM |
207 |
207 |
;;; needs to kick in |
208 |
208 |
;;:init |
209 |
209 |
;;; Old paths |
210 |
210 |
;;;(set-variable 'ycmd-server-command `("/usr/bin/python" ,(file-truename "/usr/share/vim/vimfiles/third_party/ycmd/ycmd/"))) |
211 |
211 |
;;;(set-variable 'ycmd-global-config "/home/simba/.emacs.d/lang/ycm_conf.py") |
212 |
212 |
;;(set-variable 'ycmd-server-command `("python" ,(file-truename "~/ycmd/ycmd"))) |
213 |
213 |
;;(set-variable 'ycmd-global-config (file-truename "~/Repositories/rc/.ycm_extra_conf.py")) |
214 |
214 |
;;(set-variable 'ycmd-global-modes 'all) ; Activates YCMD in 'all' major modes, |
215 |
215 |
;;; not only those in ycmd-file-type-map |
216 |
216 |
;;;(set-variable 'ycmd-extra-conf-whitelist '("/home/jorrit/Dev/*")) |
217 |
217 |
;;:config |
218 |
218 |
;;(setq url-show-status nil) ; Makes those FUCKING annoying messages SHUT THE HELL UP |
219 |
219 |
;;(setq request-message-level -1) |
220 |
220 |
|
221 |
221 |
;;(use-package flycheck-ycmd |
222 |
222 |
;;:ensure t |
223 |
223 |
;;:commands (flycheck-ycmd-setup) |
224 |
224 |
;;:hook (ycmd-mode . flycheck-ycmd-setup) |
225 |
225 |
;;:init |
226 |
226 |
;;(setq flycheck-clang-language-standard "c++11") |
227 |
227 |
;;(when (not (display-graphic-p)) |
228 |
228 |
;;(setq flycheck-indication-mode nil)))) |
229 |
229 |
|
230 |
230 |
(use-package company |
231 |
231 |
:hook (after-init . global-company-mode) |
232 |
232 |
:init |
233 |
233 |
(company-tng-configure-default) ; Use <TAB> to scroll in completion options |
234 |
234 |
(setq company-minimum-prefix-length 2) |
235 |
235 |
(setq company-idle-delay 0.0)) |
236 |
236 |
;:config |
237 |
237 |
;;(use-package company-ycmd-mode |
238 |
238 |
;;:ensure company-ycmd |
239 |
239 |
;;:commands (company-ycmd-setup) |
240 |
240 |
;;:hook (ycmd-mode . company-ycmd-setup)) |
241 |
241 |
;;(use-package company-flx |
242 |
242 |
;;:ensure t |
243 |
243 |
;;:config |
244 |
244 |
;;(company-flx-mode +1))) |
245 |
245 |
;; |
246 |
246 |
(use-package company-fuzzy |
247 |
247 |
:hook (company-mode . company-fuzzy-mode) |
248 |
248 |
:init |
249 |
249 |
(setq company-fuzzy-sorting-backend 'flx |
250 |
250 |
company-fuzzy-prefix-on-top nil |
251 |
251 |
company-fuzzy-history-backends '(company-yasnippet) |
252 |
252 |
company-fuzzy-trigger-symbols '("." "->" "<" "\"" "'" "@"))) |
253 |
253 |
|
254 |
254 |
(global-company-fuzzy-mode 1) |
255 |
255 |
|
256 |
256 |
(use-package clang-format |
257 |
257 |
:general |
258 |
258 |
(local-leader-def |
259 |
259 |
:states 'normal |
260 |
260 |
:modes '(c-mode-map c++-mode-map) |
261 |
261 |
"b" '(:ignore t :which-key "clang") |
262 |
262 |
"bf" 'clang-format-buffer) |
263 |
263 |
:init |
264 |
264 |
(setq-default clang-format-style "{BasedOnStyle: llvm, IndentWidth: 4}")) |
265 |
265 |
|
266 |
266 |
;; eViL-mode |
267 |
267 |
(use-package evil |
268 |
268 |
:hook (after-init . evil-mode) |
269 |
269 |
:bind (:map evil-normal-state-map ;; Scrolls over lines correctly |
270 |
270 |
("j" . evil-next-visual-line) |
271 |
271 |
("k" . evil-previous-visual-line)) |
272 |
272 |
:general |
273 |
273 |
(my-leader-def |
274 |
274 |
:states 'normal |
275 |
275 |
"b" '(:ignore t :which-key "buffer") |
276 |
276 |
"g" '(:ignore t :which-key "magit") |
277 |
277 |
"f" '(:ignore t :which-key "files") |
278 |
278 |
"bk" 'kill-this-buffer |
279 |
279 |
"bd" 'kill-other-buffers |
280 |
280 |
"bh" 'switch-to-home-buffer |
281 |
281 |
"br" 'revert-buffer |
282 |
282 |
"h" 'split-window-vertically |
283 |
283 |
"v" 'split-window-horizontally) |
284 |
284 |
(local-leader-def |
285 |
285 |
:states 'normal |
286 |
286 |
;; General lang options |
287 |
287 |
"c" 'compile) |
288 |
288 |
:init |
289 |
289 |
(setq evil-find-skip-newlines t) ;; Allows f/F/t/T to search beyond CR/LF |
290 |
290 |
(setq evil-set-undo-system 'undo-tree) ;; Sets EViL up to use undo (after a |
291 |
291 |
;; weird 2020 patch) |
292 |
292 |
(setq evil-want-C-u-scroll t)) ;; Activates c-u scroll to above. |
293 |
293 |
|
294 |
294 |
;; About smooth-scrolling: I'd normally just use some variables for scrolling |
295 |
295 |
;; but they all fail with org-mode. This package fixes everything that's wrong for me. |
296 |
296 |
(use-package smooth-scrolling |
297 |
- | :config |
298 |
- | (smooth-scrolling-mode 1)) |
299 |
- | |
+ |
297 |
;:config |
+ |
298 |
;(smooth-scrolling-mode 1)) |
+ |
299 |
|
300 |
300 |
(use-package org |
301 |
301 |
:pin "org" |
302 |
302 |
; FIXME This causes some errors with bind-keys or what have you. Commented |
303 |
303 |
; until it is fixed. |
304 |
304 |
;:bind (:bind-keymap |
305 |
305 |
; ("C-c x" . org-todo-state-map) |
306 |
306 |
; :map org-todo-state-map |
307 |
307 |
; ("x" . #'(lambda nil (interactive) (org-todo "CANCELLED"))) |
308 |
308 |
; ("d" . #'(lambda nil (interactive) (org-todo "DONE"))) |
309 |
309 |
; ("f" . #'(lambda nil (interactive) (org-todo "DEFERRED"))) |
310 |
310 |
; ("l" . #'(lambda nil (interactive) (org-todo "DELEGATED"))) |
311 |
311 |
; ("s" . #'(lambda nil (interactive) (org-todo "STARTED"))) |
312 |
312 |
; ("w" . #'(lambda nil (interactive) (org-todo "WAITING")))) |
313 |
313 |
; :map org-mode-map |
314 |
314 |
; ("C-c x" . org-todo-state-map)) |
315 |
315 |
:init |
316 |
316 |
(define-key mode-specific-map [?a] 'org-agenda) |
317 |
317 |
:custom |
318 |
318 |
;; Because I use XeLaTeX (it's objectively better), some variables need to be |
319 |
319 |
;; set so org-mode knows what to call. |
320 |
320 |
|
321 |
321 |
;; Okay, so you cán export asynchronous so compiling your PDF doesn't lock up |
322 |
322 |
;; the editor completely, but for one reason or another, you MUST set the |
323 |
323 |
;; async-debug to nil. Otherwise it will constantly "exit abnormally" without |
324 |
324 |
;; reason. This fixes it, who knows why. |
325 |
325 |
(org-export-async-debug nil) |
326 |
326 |
|
327 |
327 |
(org-latex-compiler 'xelatex) ; Makes sure the XeLaTeX compiler is used |
328 |
328 |
|
329 |
329 |
; Tells Org to use dvisvgm because dvipng does not support XeLaTeX's output format |
330 |
330 |
(org-preview-latex-default-process 'dvisvgm) |
331 |
331 |
|
332 |
332 |
; This edits the preview process so it works correctly with XeLaTeX. |
333 |
333 |
; Changes: |
334 |
334 |
; - "latex" to "xelatex" |
335 |
335 |
; - Added the "-no-pdf" flag so it prints an XDV file instead of PDF. |
336 |
336 |
; - change input type from dvi to xdv |
337 |
337 |
; - Only leave the dvisvgm option because I don't need the others |
338 |
338 |
(org-preview-latex-process-alist |
339 |
339 |
(quote |
340 |
340 |
((dvisvgm :programs |
341 |
341 |
("xelatex" "dvisvgm") |
342 |
342 |
:description "dvi > svg" :message "you need to install the programs: xelatex and dvisvgm." :use-xcolor t :image-input-type "xdv" :image-output-type "svg" :image-size-adjust |
343 |
343 |
(1.7 . 1.5) |
344 |
344 |
:latex-compiler |
345 |
345 |
("xelatex -interaction nonstopmode -no-pdf -output-directory %o %f") |
346 |
346 |
:image-converter |
347 |
347 |
("dvisvgm %f -n -b min -c %S -o %O"))))) |
348 |
348 |
|
349 |
349 |
;; Sets the formatting options. I only changed :scale to 1.6, but I don't know |
350 |
350 |
;; how to change only thát, so for now I'm configuring the entire variable |
351 |
351 |
(org-format-latex-options (quote |
352 |
352 |
(:foreground default :background default :scale 1.6 :html-foreground "Black" :html-background "Transparent" :html-scale 1.0 :matchers |
353 |
353 |
("begin" "$1" "$" "$$" "\\(" "\\[")))) |
354 |
354 |
|
355 |
355 |
;; Sets the directory in which the preview fragments are stored to the /tmp |
356 |
356 |
;; folder. Otherwise it clutters up the folder in which the source resides |
357 |
357 |
;; with what are essentially cache files. |
358 |
358 |
(org-preview-latex-image-directory "/tmp/ltximg/") |
359 |
359 |
|
360 |
360 |
;; Following customizations are in regard to org-agenda configuration. |
361 |
361 |
(org-agenda-files (quote ("~/shared/planning/planning.org"))) |
362 |
362 |
(org-default-notes-file "~/shared/planning/notes.org") |
363 |
363 |
(org-agenda-span 62) |
364 |
364 |
(org-deadline-warning-days 14) |
365 |
365 |
(org-agenda-show-all-dates t) |
366 |
366 |
(org-agenda-skip-deadline-if-done t) |
367 |
367 |
(org-agenda-skip-scheduled-if-done t) |
368 |
368 |
(org-agenda-start-on-weekday nil) |
369 |
369 |
(org-reverse-note-order t) |
370 |
370 |
(org-fast-tag-selection-single-key (quote expert)) |
371 |
371 |
(org-agenda-custom-commands |
372 |
372 |
(quote (("d" todo "DELEGATED" nil) |
373 |
373 |
("c" todo "DONE|DEFERRED|CANCELED" nil) |
374 |
374 |
("w" todo "WAITING" nil) |
375 |
375 |
("W" agenda "" ((org-agenda-ndays 21))) |
376 |
376 |
("A" agenda "" |
377 |
377 |
((org-agenda-skip-function |
378 |
378 |
(lambda nil |
379 |
379 |
(org-agenda-skip-entry-if (quote notregexp) "\\=.*\\[#A\\]"))) |
380 |
380 |
(org-agenda-ndays 1) |
381 |
381 |
(org-agenda-overriding-header "Today's Priority #A tasks: "))) |
382 |
382 |
("u" alltodo "" |
383 |
383 |
((org-agenda-skip-function |
384 |
384 |
(lambda nil |
385 |
385 |
(org-agenda-skip-entry-if (quote scheduled) (quote deadline) |
386 |
386 |
(quote regexp) "\n]+>"))) |
387 |
387 |
(org-agenda-overriding-header "Unscheduled TODO entries: ")))))) |
388 |
388 |
(org-capture-store-without-prompt t) |
389 |
389 |
(org-capture-templates |
390 |
390 |
(quote ((116 "* TODO %?\n %u" "~/Repositories/private/org/planning.org" "Tasks") |
391 |
391 |
(110 "* %u %?" "~/Repositories/private/org/notes.org" "Notes")))) |
392 |
392 |
(capture-annotation-functions (quote (org-capture-annotation))) |
393 |
393 |
(capture-handler-functions (quote (org-capture-handler)))) |
394 |
394 |
|
395 |
395 |
;:general |
396 |
396 |
;(local-leader-def |
397 |
397 |
; :states 'normal |
398 |
398 |
; :keymaps 'org-mode-map |
399 |
399 |
; "e" 'org-export-dispatch |
400 |
400 |
; "x" 'org-table-export |
401 |
401 |
; "." 'org-time-stamp |
402 |
402 |
; "t" 'org-twbs-export-to-html |
403 |
403 |
; "s" 'org-schedule |
404 |
404 |
; "d" 'org-deadline |
405 |
405 |
; "'" 'org-edit-special) |
406 |
406 |
; :config |
407 |
407 |
; ;; log todo items with timestamp |
408 |
408 |
; (setq org-log-done 'time)) |
409 |
409 |
|
410 |
410 |
(use-package helm |
411 |
411 |
:hook (after-init . helm-mode) |
412 |
412 |
:commands (helm-autoresize-mode) |
413 |
413 |
:init |
414 |
414 |
;; (defvar helm-google-suggest-use-curl-p) |
415 |
415 |
(defvar helm-ff-search-library-in-sexp) |
416 |
416 |
(defvar helm-echo-input-in-header-line) |
417 |
417 |
(defvar helm-ff-file-name-history-use-recentf) |
418 |
418 |
:general |
419 |
419 |
(general-define-key |
420 |
420 |
"M-x" 'helm-M-x |
421 |
421 |
"M-:" 'helm-eval-expression |
422 |
422 |
"C-c h" 'helm-command-prefix) |
423 |
423 |
(general-define-key |
424 |
424 |
:keymaps 'helm-map |
425 |
425 |
"<tab>" 'helm-execute-persistent-action |
426 |
426 |
"C-i" 'helm-execute-persistent-action |
427 |
427 |
"C-z" 'helm-select-action) |
428 |
428 |
(my-leader-def |
429 |
429 |
:states 'normal |
430 |
430 |
"bb" 'helm-buffers-list |
431 |
431 |
"ff" 'helm-find-files |
432 |
432 |
"p" 'helm-show-kill-ring) |
433 |
433 |
:config |
434 |
434 |
(setq helm-split-window-inside-p t ; open helm buffer inside current window, not occupy whole other window |
435 |
435 |
helm-move-to-line-cycle-in-source t ; move to end or beginning of source when reaching top or bottom of source. |
436 |
436 |
helm-ff-search-library-in-sexp t ; search for library in `require' and `declare-function' sexp. |
437 |
437 |
helm-scroll-amount 8 ; scroll 8 lines other window using m-<next>/m-<prior> |
438 |
438 |
helm-ff-file-name-history-use-recentf t |
439 |
439 |
helm-echo-input-in-header-line t) |
440 |
440 |
|
441 |
441 |
;; hide some autogenerated files from helm |
442 |
442 |
(setq helm-ff-skip-boring-files t) |
443 |
443 |
;; (add-to-list 'helm-boring-file-regexp-list "\\~$") |
444 |
444 |
|
445 |
445 |
(setq helm-autoresize-max-height 0) |
446 |
446 |
(setq helm-autoresize-min-height 20) |
447 |
447 |
(helm-autoresize-mode 1)) |
448 |
448 |
|
449 |
449 |
|
450 |
450 |
(use-package rainbow-delimiters |
451 |
451 |
:hook (prog-mode . rainbow-delimiters-mode)) |
452 |
452 |
|
453 |
453 |
|
454 |
454 |
;; Settings for having an LaTeX beamer class export tool |
455 |
455 |
(unless (boundp 'org-export-latex-classes) |
456 |
456 |
(setq org-export-latex-classes nil)) |
457 |
457 |
(add-to-list 'org-export-latex-classes |
458 |
458 |
;; beamer class, for presentations |
459 |
459 |
'("beamer" |
460 |
460 |
"\\documentclass[11pt]{beamer}\n |
461 |
461 |
\\mode<{{{beamermode}}}>\n |
462 |
462 |
\\usetheme{{{{beamertheme}}}}\n |
463 |
463 |
\\usecolortheme{{{{beamercolortheme}}}}\n |
464 |
464 |
\\beamertemplateballitem\n |
465 |
465 |
\\setbeameroption{show notes} |
466 |
466 |
\\usepackage[utf8]{inputenc}\n |
467 |
467 |
\\usepackage[T1]{fontenc}\n |
468 |
468 |
\\usepackage{hyperref}\n |
469 |
469 |
\\usepackage{color} |
470 |
470 |
\\usepackage{listings} |
471 |
471 |
\\lstset{numbers=none,language=[ISO]C++,tabsize=4, |
472 |
472 |
frame=single, |
473 |
473 |
basicstyle=\\small, |
474 |
474 |
showspaces=false,showstringspaces=false, |
475 |
475 |
showtabs=false, |
476 |
476 |
keywordstyle=\\color{blue}\\bfseries, |
477 |
477 |
commentstyle=\\color{red}, |
478 |
478 |
}\n |
479 |
479 |
\\usepackage{verbatim}\n |
480 |
480 |
\\institute{{{{beamerinstitute}}}}\n |
481 |
481 |
\\subject{{{{beamersubject}}}}\n" |
482 |
482 |
|
483 |
483 |
("\\section{%s}" . "\\section*{%s}") |
484 |
484 |
|
485 |
485 |
("\\begin{frame}[fragile]\\frametitle{%s}" |
486 |
486 |
"\\end{frame}" |
487 |
487 |
"\\begin{frame}[fragile]\\frametitle{%s}" |
488 |
488 |
"\\end{frame}"))) |
489 |
489 |
|
490 |
490 |
;; Adds a letter class, for formal letters |
491 |
491 |
|
492 |
492 |
(add-to-list 'org-export-latex-classes |
493 |
493 |
|
494 |
494 |
'("letter" |
495 |
495 |
"\\documentclass[11pt]{letter}\n |
496 |
496 |
\\usepackage[utf8]{inputenc}\n |
497 |
497 |
\\usepackage[T1]{fontenc}\n |
498 |
498 |
\\usepackage{color}" |
499 |
499 |
|
500 |
500 |
("\\section{%s}" . "\\section*{%s}") |
501 |
501 |
("\\subsection{%s}" . "\\subsection*{%s}") |
502 |
502 |
("\\subsubsection{%s}" . "\\subsubsection*{%s}") |
503 |
503 |
("\\paragraph{%s}" . "\\paragraph*{%s}") |
504 |
504 |
("\\subparagraph{%s}" . "\\subparagraph*{%s}"))) |
505 |
505 |
|
506 |
506 |
|
507 |
507 |
(custom-set-faces |
508 |
508 |
;; custom-set-faces was added by Custom. |
509 |
509 |
;; If you edit it by hand, you could mess it up, so be careful. |
510 |
510 |
;; Your init file should contain only one such instance. |
511 |
511 |
;; If there is more than one, they won't work right. |
512 |
512 |
) |
513 |
513 |
|
514 |
514 |
|
515 |
515 |
;; This is to fix the retarded scrolling behaviour in Emacs as much as possible: |
516 |
516 |
(setq redisplay-dont-pause t |
517 |
517 |
scroll-margin 1 |
518 |
518 |
scroll-step 1 |
519 |
519 |
scroll-conservatively 10000 |
520 |
520 |
scroll-preserve-screen-position 1) |
521 |
521 |
;; Stops Emacs from accelerating my scroll: |
522 |
522 |
(setq mouse-wheel-progressive-speed nil) |
523 |
523 |
;; Makes scrolling do 5 lines at a time, otherwise it's pretty slow |
524 |
524 |
(setq mouse-wheel-scroll-amount '(5)) |
525 |
525 |