Actually, disable that for now
[~bandali/configs] / spacemacs / .spacemacs
... / ...
CommitLineData
1;; -*- mode: emacs-lisp -*-
2;; This file is loaded by Spacemacs at startup.
3;; It must be stored in your home directory.
4
5(defun dotspacemacs/layers ()
6 "Configuration Layers declaration.
7You should not put any user code in this function besides modifying the variable
8values."
9 (setq-default
10 ;; Base distribution to use. This is a layer contained in the directory
11 ;; `+distribution'. For now available distributions are `spacemacs-base'
12 ;; or `spacemacs'. (default 'spacemacs)
13 dotspacemacs-distribution 'spacemacs
14 ;; Lazy installation of layers (i.e. layers are installed only when a file
15 ;; with a supported type is opened). Possible values are `all', `unused'
16 ;; and `nil'. `unused' will lazy install only unused layers (i.e. layers
17 ;; not listed in variable `dotspacemacs-configuration-layers'), `all' will
18 ;; lazy install any layer that support lazy installation even the layers
19 ;; listed in `dotspacemacs-configuration-layers'. `nil' disable the lazy
20 ;; installation feature and you have to explicitly list a layer in the
21 ;; variable `dotspacemacs-configuration-layers' to install it.
22 ;; (default 'unused)
23 dotspacemacs-enable-lazy-installation 'unused
24 ;; If non-nil then Spacemacs will ask for confirmation before installing
25 ;; a layer lazily. (default t)
26 dotspacemacs-ask-for-lazy-installation t
27 ;; If non-nil layers with lazy install support are lazy installed.
28 ;; List of additional paths where to look for configuration layers.
29 ;; Paths must have a trailing slash (i.e. `~/.mycontribs/')
30 dotspacemacs-configuration-layer-path '()
31 ;; List of configuration layers to load.
32 dotspacemacs-configuration-layers
33 '(
34 aminb
35 auto-completion
36 (better-defaults :variables
37 better-defaults-move-to-beginning-of-code-first t
38 better-defaults-move-to-end-of-code-first t)
39 bibtex
40 c-c++
41 emacs-lisp
42 git
43 haskell
44 html
45 ;; idris
46 ivy
47 ;; javascript
48 latex
49 markdown
50 org
51 ;; python
52 ;; racket
53 ;; rust
54 (shell :variables
55 shell-default-height 30
56 shell-default-position 'bottom)
57 shell-scripts
58 spell-checking
59 syntax-checking
60 ;; version-control
61 ;; yaml
62 )
63 ;; List of additional packages that will be installed without being
64 ;; wrapped in a layer. If you need some configuration for these
65 ;; packages, then consider creating a layer. You can also put the
66 ;; configuration in `dotspacemacs/user-config'.
67 dotspacemacs-additional-packages '()
68 ;; A list of packages that cannot be updated.
69 dotspacemacs-frozen-packages '()
70 ;; A list of packages that will not be installed and loaded.
71 dotspacemacs-excluded-packages '()
72 ;; Defines the behaviour of Spacemacs when installing packages.
73 ;; Possible values are `used-only', `used-but-keep-unused' and `all'.
74 ;; `used-only' installs only explicitly used packages and uninstall any
75 ;; unused packages as well as their unused dependencies.
76 ;; `used-but-keep-unused' installs only the used packages but won't uninstall
77 ;; them if they become unused. `all' installs *all* packages supported by
78 ;; Spacemacs and never uninstall them. (default is `used-only')
79 dotspacemacs-install-packages 'used-only))
80
81(defun dotspacemacs/init ()
82 "Initialization function.
83This function is called at the very startup of Spacemacs initialization
84before layers configuration.
85You should not put any user code in there besides modifying the variable
86values."
87 ;; This setq-default sexp is an exhaustive list of all the supported
88 ;; spacemacs settings.
89 (setq-default
90 ;; If non-nil ELPA repositories are contacted via HTTPS whenever it's
91 ;; possible. Set it to nil if you have no way to use HTTPS in your
92 ;; environment, otherwise it is strongly recommended to let it set to t.
93 ;; This variable has no effect if Emacs is launched with the parameter
94 ;; `--insecure' which forces the value of this variable to nil.
95 ;; (default t)
96 dotspacemacs-elpa-https t
97 ;; Maximum allowed time in seconds to contact an ELPA repository.
98 dotspacemacs-elpa-timeout 5
99 ;; If non-nil then spacemacs will check for updates at startup
100 ;; when the current branch is not `develop'. Note that checking for
101 ;; new versions works via git commands, thus it calls GitHub services
102 ;; whenever you start Emacs. (default nil)
103 dotspacemacs-check-for-update nil
104 ;; If non-nil, a form that evaluates to a package directory. For example, to
105 ;; use different package directories for different Emacs versions, set this
106 ;; to `emacs-version'.
107 dotspacemacs-elpa-subdirectory nil
108 ;; One of `vim', `emacs' or `hybrid'.
109 ;; `hybrid' is like `vim' except that `insert state' is replaced by the
110 ;; `hybrid state' with `emacs' key bindings. The value can also be a list
111 ;; with `:variables' keyword (similar to layers). Check the editing styles
112 ;; section of the documentation for details on available variables.
113 ;; (default 'vim)
114 dotspacemacs-editing-style 'emacs
115 ;; If non-nil output loading progress in `*Messages*' buffer. (default nil)
116 dotspacemacs-verbose-loading nil
117 ;; Specify the startup banner. Default value is `official', it displays
118 ;; the official spacemacs logo. An integer value is the index of text
119 ;; banner, `random' chooses a random text banner in `core/banners'
120 ;; directory. A string value must be a path to an image format supported
121 ;; by your Emacs build.
122 ;; If the value is nil then no banner is displayed. (default 'official)
123 dotspacemacs-startup-banner 'official
124 ;; List of items to show in startup buffer or an association list of
125 ;; the form `(list-type . list-size)`. If nil then it is disabled.
126 ;; Possible values for list-type are:
127 ;; `recents' `bookmarks' `projects' `agenda' `todos'."
128 ;; List sizes may be nil, in which case
129 ;; `spacemacs-buffer-startup-lists-length' takes effect.
130 dotspacemacs-startup-lists '((recents . 5)
131 (projects . 7))
132 ;; True if the home buffer should respond to resize events.
133 dotspacemacs-startup-buffer-responsive t
134 ;; Default major mode of the scratch buffer (default `text-mode')
135 dotspacemacs-scratch-mode 'text-mode
136 ;; List of themes, the first of the list is loaded when spacemacs starts.
137 ;; Press <SPC> T n to cycle to the next theme in the list (works great
138 ;; with 2 themes variants, one dark and one light)
139 dotspacemacs-themes '(spacemacs-dark
140 spacemacs-light)
141 ;; If non-nil the cursor color matches the state color in GUI Emacs.
142 dotspacemacs-colorize-cursor-according-to-state t
143 ;; Default font, or prioritized list of fonts. `powerline-scale' allows to
144 ;; quickly tweak the mode-line size to make separators look not too crappy.
145 dotspacemacs-default-font '("Inconsolata"
146 :size 15
147 :weight normal
148 :width normal
149 :powerline-scale 1.6)
150 ;; The leader key
151 dotspacemacs-leader-key "SPC"
152 ;; The key used for Emacs commands (M-x) (after pressing on the leader key).
153 ;; (default "SPC")
154 dotspacemacs-emacs-command-key "SPC"
155 ;; The key used for Vim Ex commands (default ":")
156 dotspacemacs-ex-command-key ":"
157 ;; The leader key accessible in `emacs state' and `insert state'
158 ;; (default "M-m")
159 dotspacemacs-emacs-leader-key "S-SPC"
160 ;; Major mode leader key is a shortcut key which is the equivalent of
161 ;; pressing `<leader> m`. Set it to `nil` to disable it. (default ",")
162 dotspacemacs-major-mode-leader-key ","
163 ;; Major mode leader key accessible in `emacs state' and `insert state'.
164 ;; (default "C-M-m")
165 dotspacemacs-major-mode-emacs-leader-key "M-SPC"
166 ;; These variables control whether separate commands are bound in the GUI to
167 ;; the key pairs C-i, TAB and C-m, RET.
168 ;; Setting it to a non-nil value, allows for separate commands under <C-i>
169 ;; and TAB or <C-m> and RET.
170 ;; In the terminal, these pairs are generally indistinguishable, so this only
171 ;; works in the GUI. (default nil)
172 dotspacemacs-distinguish-gui-tab nil
173 ;; If non-nil `Y' is remapped to `y$' in Evil states. (default nil)
174 dotspacemacs-remap-Y-to-y$ nil
175 ;; If non-nil, the shift mappings `<' and `>' retain visual state if used
176 ;; there. (default t)
177 dotspacemacs-retain-visual-state-on-shift t
178 ;; If non-nil, J and K move lines up and down when in visual mode.
179 ;; (default nil)
180 dotspacemacs-visual-line-move-text nil
181 ;; If non-nil, inverse the meaning of `g' in `:substitute' Evil ex-command.
182 ;; (default nil)
183 dotspacemacs-ex-substitute-global nil
184 ;; Name of the default layout (default "Default")
185 dotspacemacs-default-layout-name "Default"
186 ;; If non-nil the default layout name is displayed in the mode-line.
187 ;; (default nil)
188 dotspacemacs-display-default-layout nil
189 ;; If non-nil then the last auto saved layouts are resume automatically upon
190 ;; start. (default nil)
191 dotspacemacs-auto-resume-layouts nil
192 ;; Size (in MB) above which spacemacs will prompt to open the large file
193 ;; literally to avoid performance issues. Opening a file literally means that
194 ;; no major mode or minor modes are active. (default is 1)
195 dotspacemacs-large-file-size 1
196 ;; Location where to auto-save files. Possible values are `original' to
197 ;; auto-save the file in-place, `cache' to auto-save the file to another
198 ;; file stored in the cache directory and `nil' to disable auto-saving.
199 ;; (default 'cache)
200 dotspacemacs-auto-save-file-location 'cache
201 ;; Maximum number of rollback slots to keep in the cache. (default 5)
202 dotspacemacs-max-rollback-slots 5
203 ;; If non-nil, `helm' will try to minimize the space it uses. (default nil)
204 dotspacemacs-helm-resize nil
205 ;; if non-nil, the helm header is hidden when there is only one source.
206 ;; (default nil)
207 dotspacemacs-helm-no-header nil
208 ;; define the position to display `helm', options are `bottom', `top',
209 ;; `left', or `right'. (default 'bottom)
210 dotspacemacs-helm-position 'bottom
211 ;; Controls fuzzy matching in helm. If set to `always', force fuzzy matching
212 ;; in all non-asynchronous sources. If set to `source', preserve individual
213 ;; source settings. Else, disable fuzzy matching in all sources.
214 ;; (default 'always)
215 dotspacemacs-helm-use-fuzzy 'always
216 ;; If non-nil the paste micro-state is enabled. When enabled pressing `p`
217 ;; several times cycle between the kill ring content. (default nil)
218 dotspacemacs-enable-paste-transient-state nil
219 ;; Which-key delay in seconds. The which-key buffer is the popup listing
220 ;; the commands bound to the current keystroke sequence. (default 0.4)
221 dotspacemacs-which-key-delay 0.4
222 ;; Which-key frame position. Possible values are `right', `bottom' and
223 ;; `right-then-bottom'. right-then-bottom tries to display the frame to the
224 ;; right; if there is insufficient space it displays it at the bottom.
225 ;; (default 'bottom)
226 dotspacemacs-which-key-position 'bottom
227 ;; Control where `switch-to-buffer' displays the buffer. If nil,
228 ;; `switch-to-buffer' displays the buffer in the current window even if
229 ;; another same-purpose window is available. If non-nil, `switch-to-buffer'
230 ;; displays the buffer in a same-purpose window even if the buffer can be
231 ;; displayed in the current window. (default nil)
232 dotspacemacs-switch-to-buffer-prefers-purpose nil
233 ;; If non-nil a progress bar is displayed when spacemacs is loading. This
234 ;; may increase the boot time on some systems and emacs builds, set it to
235 ;; nil to boost the loading time. (default t)
236 dotspacemacs-loading-progress-bar t
237 ;; If non-nil the frame is fullscreen when Emacs starts up. (default nil)
238 ;; (Emacs 24.4+ only)
239 dotspacemacs-fullscreen-at-startup nil
240 ;; If non-nil `spacemacs/toggle-fullscreen' will not use native fullscreen.
241 ;; Use to disable fullscreen animations in OSX. (default nil)
242 dotspacemacs-fullscreen-use-non-native nil
243 ;; If non-nil the frame is maximized when Emacs starts up.
244 ;; Takes effect only if `dotspacemacs-fullscreen-at-startup' is nil.
245 ;; (default nil) (Emacs 24.4+ only)
246 dotspacemacs-maximized-at-startup nil
247 ;; A value from the range (0..100), in increasing opacity, which describes
248 ;; the transparency level of a frame when it's active or selected.
249 ;; Transparency can be toggled through `toggle-transparency'. (default 90)
250 dotspacemacs-active-transparency 90
251 ;; A value from the range (0..100), in increasing opacity, which describes
252 ;; the transparency level of a frame when it's inactive or deselected.
253 ;; Transparency can be toggled through `toggle-transparency'. (default 90)
254 dotspacemacs-inactive-transparency 90
255 ;; If non-nil show the titles of transient states. (default t)
256 dotspacemacs-show-transient-state-title t
257 ;; If non-nil show the color guide hint for transient state keys. (default t)
258 dotspacemacs-show-transient-state-color-guide t
259 ;; If non-nil unicode symbols are displayed in the mode line. (default t)
260 dotspacemacs-mode-line-unicode-symbols t
261 ;; If non-nil smooth scrolling (native-scrolling) is enabled. Smooth
262 ;; scrolling overrides the default behavior of Emacs which recenters point
263 ;; when it reaches the top or bottom of the screen. (default t)
264 dotspacemacs-smooth-scrolling t
265 ;; If non-nil line numbers are turned on in all `prog-mode' and `text-mode'
266 ;; derivatives. If set to `relative', also turns on relative line numbers.
267 ;; (default nil)
268 dotspacemacs-line-numbers nil
269 ;; Code folding method. Possible values are `evil' and `origami'.
270 ;; (default 'evil)
271 dotspacemacs-folding-method 'evil
272 ;; If non-nil smartparens-strict-mode will be enabled in programming modes.
273 ;; (default nil)
274 dotspacemacs-smartparens-strict-mode nil
275 ;; If non-nil pressing the closing parenthesis `)' key in insert mode passes
276 ;; over any automatically added closing parenthesis, bracket, quote, etc…
277 ;; This can be temporary disabled by pressing `C-q' before `)'. (default nil)
278 dotspacemacs-smart-closing-parenthesis nil
279 ;; Select a scope to highlight delimiters. Possible values are `any',
280 ;; `current', `all' or `nil'. Default is `all' (highlight any scope and
281 ;; emphasis the current one). (default 'all)
282 dotspacemacs-highlight-delimiters 'all
283 ;; If non-nil, advise quit functions to keep server open when quitting.
284 ;; (default nil)
285 dotspacemacs-persistent-server nil
286 ;; List of search tool executable names. Spacemacs uses the first installed
287 ;; tool of the list. Supported tools are `rg', `ag', `pt', `ack' and `grep'.
288 ;; (default '("rg" "ag" "pt" "ack" "grep"))
289 dotspacemacs-search-tools '("rg" "ag" "pt" "ack" "grep")
290 ;; The default package repository used if no explicit repository has been
291 ;; specified with an installed package.
292 ;; Not used for now. (default nil)
293 dotspacemacs-default-package-repository nil
294 ;; Delete whitespace while saving buffer. Possible values are `all'
295 ;; to aggressively delete empty line and long sequences of whitespace,
296 ;; `trailing' to delete only the whitespace at end of lines, `changed'to
297 ;; delete only whitespace for changed lines or `nil' to disable cleanup.
298 ;; (default nil)
299 dotspacemacs-whitespace-cleanup nil
300 ))
301
302(defun dotspacemacs/user-init ()
303 "Initialization function for user code.
304It is called immediately after `dotspacemacs/init', before layer configuration
305executes.
306 This function is mostly useful for variables that need to be set
307before packages are loaded. If you are unsure, you should try in setting them in
308`dotspacemacs/user-config' first."
309 )
310
311(defun dotspacemacs/user-config ()
312 "Configuration function for user code.
313This function is called at the very end of Spacemacs initialization after
314layers configuration.
315This is the place where most of your configurations should be done. Unless it is
316explicitly specified that a variable should be set before a package is loaded,
317you should place your code here."
318
319 (setq powerline-default-separator 'slant)
320
321 ;; (setq magit-commit-arguments '("--signoff"
322 ;; "--gpg-sign=4E05246AB0BF7FFB"))
323
324 (setq undo-tree-auto-save-history t
325 undo-tree-history-directory-alist
326 `(("." . ,(concat spacemacs-cache-directory "undo"))))
327 (unless (file-exists-p (concat spacemacs-cache-directory "undo"))
328 (make-directory (concat spacemacs-cache-directory "undo")))
329
330 ;; Use pdflatex instead of latex
331 (setq TeX-PDF-mode t
332 TeX-engine 'xetex)
333
334 ;; Support zathura in TeX mode
335 (setq TeX-view-program-selection
336 '(((output-dvi style-pstricks)
337 "dvips and gv")
338 (output-dvi "xdvi")
339 (output-pdf "zathura")
340 (output-html "xdg-open")))
341 (setq TeX-view-program-list
342 '(("zathura"
343 ("zathura" (mode-io-correlate "-sync.sh")
344 " "
345 (mode-io-correlate "%n:1:%t ")
346 "%o"))))
347
348 ;; Swap : and ;
349 ;; (define-key evil-motion-state-map ";" 'evil-ex)
350 ;; (define-key evil-motion-state-map ":" 'evil-repeat-find-char)
351
352 ;; Set the erc nick completion postfix to ", "
353 ;; (setq erc-pcomplete-nick-postfix ", ")
354 )
355
356;; Do not write anything past this comment. This is where Emacs will
357;; auto-generate custom variable definitions.
358(defun dotspacemacs/emacs-custom-settings ()
359 "Emacs custom settings.
360This is an auto-generated function, do not modify its content directly, use
361Emacs customize menu instead.
362This function is called at the very end of Spacemacs initialization."
363(custom-set-variables
364 ;; custom-set-variables was added by Custom.
365 ;; If you edit it by hand, you could mess it up, so be careful.
366 ;; Your init file should contain only one such instance.
367 ;; If there is more than one, they won't work right.
368 '(package-selected-packages
369 (quote
370 (web-mode web-beautify tagedit slim-mode scss-mode sass-mode pug-mode org-ref key-chord livid-mode skewer-mode simple-httpd less-css-mode json-mode json-snatcher json-reformat js2-refactor multiple-cursors js2-mode js-doc insert-shebang helm-bibtex parsebib haml-mode fish-mode emmet-mode disaster company-web web-completion-data company-tern dash-functional tern company-shell company-c-headers coffee-mode cmake-mode clang-format biblio biblio-core xterm-color ws-butler writeroom-mode window-numbering which-key wgrep volatile-highlights vi-tilde-fringe uuidgen use-package toc-org spacemacs-theme spaceline smex smeargle shell-pop restart-emacs request rainbow-delimiters quelpa popwin persp-mode pcre2el paradox orgit org-projectile org-present org-pomodoro org-plus-contrib org-download org-bullets open-junk-file neotree mwim multi-term move-text mmm-mode markdown-toc magit-gitflow macrostep lorem-ipsum linum-relative link-hint ivy-purpose ivy-hydra intero info+ indent-guide ido-vertical-mode hungry-delete htmlize hlint-refactor hl-todo hindent highlight-parentheses highlight-numbers highlight-indentation hide-comnt help-fns+ helm-make haskell-snippets google-translate golden-ratio gnuplot gitignore-mode gitconfig-mode gitattributes-mode git-timemachine git-messenger git-link gh-md flyspell-correct-ivy flycheck-pos-tip flycheck-haskell flx-ido fill-column-indicator fancy-battery eyebrowse expand-region exec-path-from-shell evil-visualstar evil-visual-mark-mode evil-unimpaired evil-tutor evil-surround evil-search-highlight-persist evil-numbers evil-nerd-commenter evil-mc evil-matchit evil-magit evil-lisp-state evil-indent-plus evil-iedit-state evil-exchange evil-escape evil-ediff evil-args evil-anzu eval-sexp-fu eshell-z eshell-prompt-extras esh-help elisp-slime-nav dumb-jump define-word crux counsel-projectile company-statistics company-ghci company-ghc company-cabal company-auctex column-enforce-mode cmm-mode clean-aindent-mode auto-yasnippet auto-highlight-symbol auto-dictionary auto-compile auctex-latexmk aggressive-indent adaptive-wrap ace-window ace-link ac-ispell))))
371(custom-set-faces
372 ;; custom-set-faces was added by Custom.
373 ;; If you edit it by hand, you could mess it up, so be careful.
374 ;; Your init file should contain only one such instance.
375 ;; If there is more than one, they won't work right.
376 )
377)