Last active
June 14, 2018 00:30
-
-
Save vodik/868efd1368c74bb945e85505cb4dde3f to your computer and use it in GitHub Desktop.
Emacs config (WIP backup before I move it to a repo)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;; -*- lexical-binding:t -*- | |
(setq gc-cons-threshold 64000000 | |
gc-cons-percentage 0.6) | |
(add-hook 'after-init-hook | |
'(lambda () (setq gc-cons-threshold 800000 | |
gc-cons-percentage 0.1))) | |
(defalias 'yes-or-no-p 'y-or-n-p) | |
(add-to-list 'default-frame-alist '(font . "Fira Code 10")) | |
(tool-bar-mode -1) | |
(menu-bar-mode -1) | |
(scroll-bar-mode -1) | |
(xterm-mouse-mode 1) | |
(setq initial-buffer-choice t | |
inhibit-startup-screen t | |
inhibit-startup-message t | |
package-enable-at-startup nil | |
package-archives '(("melpa" . "https://melpa.org/packages/") | |
("gnu" . "https://elpa.gnu.org/packages/"))) | |
(eval-when-compile | |
(require 'package) | |
(when (version< emacs-version "27.0") | |
(package-initialize)) | |
(unless (package-installed-p 'use-package) | |
(package-refresh-contents) | |
(package-install 'use-package)) | |
(require 'use-package) | |
(setq use-package-always-ensure t)) | |
(use-package diminish) | |
(use-package general) | |
(use-package neotree | |
:commands (neotree-toggle neotree-projectile-action) | |
:general | |
(:states 'normal | |
:prefix "\\" | |
"tt" 'neotree-toggle | |
"pt" 'neotree-projectile-action)) | |
;; EVIL | |
(use-package evil | |
:init | |
(progn | |
(setq evil-want-integration nil) | |
(evil-mode 1)) | |
:config | |
(progn | |
(evil-ex-define-cmd "W[rite]" 'evil-write) | |
(evil-ex-define-cmd "Wa[ll]" 'evil-write-all) | |
(evil-ex-define-cmd "Q[uit]" 'evil-quit) | |
(evil-ex-define-cmd "Wq" 'evil-save-and-close) | |
(evil-ex-define-cmd "Quita[ll]" 'evil-quit-all) | |
(evil-ex-define-cmd "Qa[ll]" "quitall")) | |
:general | |
(:states 'normal | |
"j" 'evil-next-visual-line | |
"k" 'evil-previous-visual-line) | |
(:prefix "\\" :states 'normal | |
"x" 'delete-trailing-whitespace)) | |
(use-package evil-collection | |
:after (evil neotree) | |
:config | |
(evil-collection-init)) | |
(use-package evil-commentary | |
:after evil | |
:diminish evil-commentary-mode | |
:init (evil-commentary-mode)) | |
(use-package evil-matchit | |
:after evil | |
:init (global-evil-matchit-mode 1)) | |
(use-package evil-goggles | |
:after evil | |
:diminish evil-goggles-mode | |
:init (evil-goggles-mode)) | |
;; POWERLINE/AIRLINE | |
(use-package powerline | |
:custom | |
(powerline-utf-8-separator-left #xe0b0) | |
(powerline-utf-8-separator-right #xe0b2) | |
(powerline-default-separator nil)) | |
(use-package airline-themes | |
:after (evil powerline) | |
:custom | |
(airline-display-directory 'disabled) | |
(airline-utf-glyph-separator-left #xe0b0) | |
(airline-utf-glyph-separator-right #xe0b2) | |
(airline-utf-glyph-subseparator-left #xe0b1) | |
(airline-utf-glyph-subseparator-right #xe0b3) | |
(airline-utf-glyph-branch #xe0a0) | |
(airline-utf-glyph-readonly #xe0a2) | |
(airline-utf-glyph-linenumber #xe0a1)) | |
;; THEMES | |
(use-package material-theme :defer t) | |
(use-package monokai-theme :defer t) | |
(use-package molokai-theme :defer t) | |
(use-package spacemacs-theme :defer t) | |
(use-package doom-themes | |
:defer t | |
:after neotree | |
:config | |
(doom-themes-neotree-config) | |
(doom-themes-org-config) | |
(doom-themes-visual-bell-config)) | |
(use-package solaire-mode | |
:init | |
(solaire-mode) | |
:hook ((after-change-major-mode . turn-on-solaire-mode))) | |
(defun vodik/set-theme () | |
(interactive) | |
(load-theme 'doom-one t) | |
(load-theme 'airline-doom-one t)) | |
(defun vodik/set-theme-in-frame (frame) | |
(with-selected-frame frame | |
(vodik/set-theme)) | |
(remove-hook 'after-make-frame-functions | |
'vodik/set-theme-in-frame)) | |
(if (daemonp) | |
(add-hook 'after-make-frame-functions | |
'vodik/set-theme-in-frame) | |
(vodik/set-theme)) | |
;; DELIMITERS | |
(use-package rainbow-delimiters | |
:hook ((prog-mode . rainbow-delimiters-mode))) | |
;; RANGER | |
(use-package ranger | |
:commands (ranger deer) | |
:custom | |
(ranger-override-dired-mode t)) | |
;; UNDO TREE | |
(use-package undo-tree | |
:diminish undo-tree-mode | |
:init (global-undo-tree-mode) | |
:general | |
(:prefix "\\" :states 'normal "u" #'undo-tree-visualize) | |
:custom | |
(undo-tree-auto-save-history t) | |
(undo-tree-enable-undo-in-region nil "Workaround bug") | |
(undo-tree-history-directory-alist | |
`((".*" . ,(locate-user-emacs-file "undotree"))))) | |
;; SAFE HISTORY | |
(use-package savehist | |
:init (savehist-mode 1) | |
:custom | |
(savehist-additional-variables '(search-ring regexp-search-ring)) | |
(savehist-autosave-interval 60) | |
(savehist-file (locate-user-emacs-file "savehist"))) | |
(add-hook 'text-mode-hook 'turn-on-visual-line-mode) | |
(diminish 'visual-line-mode) | |
;; RELATIVE LINE NUMBERS | |
(use-package linum-relative | |
:diminish linum-relative-mode | |
:hook ((prog-mode . linum-relative-mode)) | |
:custom | |
(linum-relative-current-symbol "") | |
(linum-relative-backend (if (version< emacs-version "26.0") | |
'linum-mode | |
'display-line-numbers-mode))) | |
;; BETTER BUFFER NAMES | |
(use-package uniquify | |
:ensure nil | |
:custom | |
(uniquify-buffer-name-style 'forward)) | |
;; SMOOTH SCROLLING | |
(use-package smooth-scrolling | |
:init (smooth-scrolling-mode 1) | |
:custom | |
(smooth-scroll-margin 5)) | |
;; COMPANY | |
(use-package company | |
:defer t | |
:diminish company-mode | |
:init (global-company-mode) | |
:general | |
(:keymaps 'company-active-map | |
[tab] 'company-complete-common-or-cycle | |
[backtab] 'company-select-previous | |
[return] 'nil | |
"TAB" 'company-complete-common-or-cycle | |
"S-TAB" 'company-select-previous | |
"RET" 'nil | |
"C-j" 'company-complete-selection) | |
:custom | |
(company-frontends '(company-tng-frontend | |
company-pseudo-tooltip-frontend | |
company-echo-metadata-frontend)) | |
(company-idle-delay 0.2) | |
(company-minimum-prefix-length 1) | |
(company-require-match nil) | |
(company-selection-wrap-around t) | |
(company-tooltip-align-annotations t)) | |
;; EMOJI | |
(use-package emojify | |
:after company | |
:hook | |
((org-mode . emojify-mode) | |
(markdown-mode . emojify-mode) | |
(git-commit-mode . emojify-mode) | |
(notmuch-show-mode . emojify-mode) | |
(notmuch-search-mode . emojify-mode)) | |
:general | |
("C-c e" #'emojify-insert-emoji) | |
:custom | |
(emojify-emoji-styles '(github unicode))) | |
;; CODE CHECKING | |
(use-package flycheck | |
:defer t | |
:diminish flycheck-mode | |
:init (global-flycheck-mode)) | |
;; SPELL CHECKING | |
(use-package flyspell | |
:diminish flyspell-mode | |
:hook ((prog-mode . flyspell-prog-mode) | |
(text-mode . flyspell-mode))) | |
;; GIT | |
(use-package magit | |
:general | |
(:prefix "\\" :states 'normal "G" #'magit-status) | |
:custom | |
(magit-popup-show-common-commands nil)) | |
(use-package gitattributes-mode | |
:mode ("/\\.gitattributes\\'" | |
"/info/attributes\\'" | |
"/git/attributes\\'")) | |
(use-package gitconfig-mode | |
:mode ("/\\.gitconfig\\'" | |
"/\\.git/config\\'" | |
"/modules/.*/config\\'" | |
"/git/config\\'" | |
"/\\.gitmodules\\'" | |
"/etc/gitconfig\\'")) | |
(use-package gitignore-mode | |
:mode ("/\\.gitignore\\'" | |
"/info/exclude\\'" | |
"/git/ignore\\'")) | |
;; BROKEN AT THE MOMENT | |
;; (use-package magithub | |
;; :after magit | |
;; :config | |
;; (magithub-feature-autoinject t) | |
;; :custom | |
;; (magithub-clone-default-directory "~/src")) | |
(use-package evil-magit | |
:after evil | |
:custom | |
(evil-magit-want-horizontal-movement nil)) | |
;; PYTHON | |
(use-package python-mode | |
:defer t | |
:mode ("\\.py\\'" . python-mode) | |
:interpreter (("python" . python-mode) | |
("python3" . python-mode) | |
("ipython" . python-mode) | |
("ipython3" . python-mode)) | |
:custom | |
(python-shell-interpreter "python3")) | |
(use-package eldoc :diminish eldoc-mode) | |
(use-package anaconda-mode | |
:hook ((python-mode . anaconda-mode) | |
(python-mode . anaconda-eldoc-mode)) | |
:general | |
(:keymaps 'python-mode-map | |
:states 'normal | |
:prefix "\\" | |
"hh" #'anaconda-mode-show-doc | |
"ga" #'anaconda-mode-find-assignments | |
"gb" #'anaconda-mode-go-back | |
"gu" #'anaconda-mode-find-references)) | |
(use-package company-anaconda | |
:defer t | |
:after company | |
:init | |
(add-to-list 'company-backends #'company-anaconda)) | |
(use-package pipenv | |
:hook ((python-mode . pipenv-mode)) | |
:general | |
(:keymaps 'python-mode-map | |
:states 'normal | |
:prefix "\\" | |
"Va" #'pipenv-activate | |
"Vd" #'pipenv-deactivate | |
"Vs" #'pipenv-shell)) | |
(use-package cython-mode | |
:mode ("\\.pyx\\'" . cython-mode) | |
:general | |
(:keymaps 'cython-mode-map | |
:states 'normal | |
:prefix "\\" | |
"hh" #'anaconda-mode-show-doc | |
"gu" #'anaconda-mode-find-references)) | |
(use-package py-isort | |
:general | |
(:keymaps 'python-mode-map | |
:states 'normal | |
:prefix "\\" | |
"rI" #'py-isort-buffer)) | |
(use-package yapfify | |
:general | |
(:keymaps 'python-mode-map | |
:states 'normal | |
:prefix "\\" | |
"=" #'yapfify-buffer)) | |
;; SEMANTIC MODE | |
(use-package semantic | |
:hook ((prog-mode . semantic-mode)) | |
:custom | |
(semanticdb-find-default-throttle '(file local project))) | |
(use-package stickyfunc-enhance | |
:after semantic | |
:init | |
(add-to-list 'semantic-default-submodes 'global-semantic-stickyfunc-mode)) | |
;; DOCKER | |
(use-package dockerfile-mode | |
:mode ("Dockerfile\\'" . dockerfile-mode)) | |
(use-package docker-compose-mode | |
:mode ("docker-compose.yml\\'". docker-compose-mode)) | |
(use-package docker-tramp) | |
;; LISPY | |
(use-package lispy | |
:hook ((emacs-lisp-mode . lispyville-mode) | |
(clojure-mode . lispyville-mode) | |
(hy-mode . lispyville-mode))) | |
(use-package lispyville | |
:hook (lispy-mode . lispyville-mode)) | |
;; HY | |
(use-package hy-mode | |
:mode ("\\.hy\\'" . hy-mode) | |
:interpreter ("hy" . hy-mode)) | |
;; ELM | |
(use-package elm-mode | |
:mode ("\\.elm\\'" . elm-mode) | |
:after company | |
:init | |
(add-to-list 'company-backends #'company-elm) | |
:general | |
(:keymaps 'elm-mode-map | |
:states 'normal | |
:prefix "\\" | |
"=" 'elm-mode-format-buffer | |
"cb" 'elm-compile-buffer | |
"cm" 'elm-compile-main | |
"hd" 'elm-documentation-lookup | |
"hh" 'elm-oracle-doc-at-point | |
"ht" 'elm-oracle-type-at-point | |
"rI" 'elm-sort-imports | |
"Rn" 'elm-preview-buffer | |
"Rm" 'elm-preview-main)) | |
;; LUA | |
(use-package lua-mode | |
:mode ("\\.lua\\'" . lua-mode) | |
:interpreter ("lua" . lua-mode) | |
:hook ((company . lua-mode-hook))) | |
;; GROOVY | |
(use-package groovy-mode | |
:mode ("Jenkinsfile\\'" . groovy-mode)) | |
;; IVY | |
(use-package ivy | |
:diminish ivy-mode | |
:init (ivy-mode 1) | |
:general | |
(:prefix "\\" :states 'normal "l" 'ivy-switch-buffer) | |
:custom | |
(ivy-height 15) | |
(ivy-use-virtual-buffers t) | |
(enable-recursive-minibuffers t)) | |
(use-package swiper | |
:general | |
("C-s" 'swiper) | |
(:prefix "\\" :states 'normal "/" 'swiper)) | |
(use-package counsel | |
:general | |
("M-x" 'counsel-M-x) | |
(:states 'normal | |
:prefix "\\" | |
"ff" 'counsel-find-file | |
"fg" 'counsel-rg | |
"fs" 'counsel-semantic | |
"hf" 'counsel-describe-function | |
"hv" 'counsel-describe-variable | |
"pf" 'counsel-git | |
"pg" 'counsel-git-grep) | |
:custom | |
(counsel-git-cmd "rg --files") | |
(counsel-rg-base-command "rg -i -M 120 --no-heading --line-number --color never %s .")) | |
(use-package flyspell-correct-ivy | |
:after flyspell | |
:general | |
(:states 'normal "z=" 'flyspell-correct-word-generic)) | |
;; PROJECTILE | |
(use-package projectile | |
:diminish projectile-mode | |
:init (projectile-mode) | |
:general | |
(:states 'normal :prefix "\\" "pp" 'projectile-switch-project) | |
:custom | |
(projectile-completion-system 'ivy)) | |
;; WHITE SPACE | |
(use-package ws-butler | |
:diminish ws-butler-mode | |
:config (ws-butler-global-mode t) | |
:custom | |
(ws-butler-keep-whitespace-before-point nil) | |
(ws-butler-trim-predicate (lambda (beg end) | |
(not (eq 'font-lock-string-face | |
(get-text-property end 'face)))))) | |
(use-package winner | |
:init (winner-mode)) | |
;; EDITORCONFIG | |
(use-package editorconfig | |
:diminish editorconfig-mode | |
:config (editorconfig-mode 1)) | |
;; PKGBUILD | |
(use-package pkgbuild-mode | |
:mode ("PKGBUILD\\'" . pkgbuild-mode)) | |
;; MARKDOWN | |
(use-package markdown-mode | |
:commands (markdown-mode gfm-mode) | |
:mode (("README\\.md\\'" . gtf-mode) | |
("\\.md\\'" . markdown-mode))) | |
;; YAML | |
(use-package yaml-mode | |
:mode ("\\.\\(yml\\|yaml\\)\\'" . yaml-mode)) | |
;; SALT | |
(use-package salt-mode | |
:mode ("\\.sls\\'" . salt-mode)) | |
(use-package feature-mode | |
:mode ("\\.feature$" . feature-mode)) | |
;; JSON | |
(use-package json-mode | |
:mode ("\\(.json\\|Pipfile.lock\\)\\'" . json-mode)) | |
;; TOML | |
(use-package toml-mode | |
:mode ("\\Pipfile\\'" . toml-mode)) | |
;; SYSTEMD | |
(use-package systemd | |
:mode ("\\.\\(service\\|mount\\|device\\|socket\\)\'" . systemd-mode)) | |
(use-package gnus-alias | |
:defer t | |
:custom | |
(gnus-alias-default-identity "vodik") | |
(gnus-alias-identity-alist | |
'(("vodik" | |
nil | |
"Simon Gomizelj <[email protected]>" | |
nil | |
(("Bcc" . "[email protected]")) | |
nil) | |
("sangoma" | |
nil | |
"Simon Gomizelj <[email protected]>" | |
"Sangoma" | |
(("Bcc" . "[email protected]")) | |
nil))) | |
(gnus-alias-identity-rules '(("work" ("any" "@sangoma\\.com" both) "sangoma"))) | |
(gnus-alias-override-user-mail-address t)) | |
(use-package message | |
:ensure nil | |
:defer t | |
:hook ((message-setup . gnus-alias-determine-identity)) | |
:general | |
(:keymaps 'message-mode-map | |
"C-c C-f" 'gnus-alias-select-identity) | |
:custom | |
(mail-envelope-from 'header) | |
(mail-host-address "vodik.xyz") | |
(mail-interactive t) | |
(mail-specify-envelope-from t) | |
(message-fcc-handler-function 'message-do-fcc) | |
(message-send-mail-function 'message-send-mail-with-sendmail) | |
(message-sendmail-envelope-from 'header) | |
(sendmail-program "/usr/bin/msmtp")) | |
(use-package notmuch | |
:commands notmuch | |
:general | |
(:states 'normal :prefix "\\" "m" #'notmuch) | |
:custom | |
(notmuch-fcc-dirs nil) | |
(notmuch-maildir-use-notmuch-insert t) | |
(notmuch-mua-user-agent-function 'notmuch-mua-user-agent-full) | |
(notmuch-search-oldest-first nil) | |
(notmuch-saved-searches | |
'((:name "inbox" :query "tag:inbox" :key "i") | |
(:name "sangoma" :query "tag:sangoma" :key "s") | |
(:name "archlinux" :query "tag:archlinux" :key "a") | |
(:name "github" :query "tag:github" :key "g") | |
(:name "lists" :query "tag:lists" :key "l") | |
(:name "unread" :query "tag:unread" :key "u"))) | |
:config | |
(evil-define-key 'normal notmuch-show-mode-map | |
"." 'notmuch-show-part-map)) | |
;; :config | |
;; (progn | |
;; (defun vodik/notmuch-show-view-as-patch () | |
;; "View the the current message as a patch." | |
;; (interactive) | |
;; (let* ((id (notmuch-show-get-message-id)) | |
;; (msg (notmuch-show-get-message-properties)) | |
;; (part (notmuch-show-get-part-properties)) | |
;; (subject (concat "Subject: " (notmuch-show-get-subject) "\n")) | |
;; (diff-default-read-only t) | |
;; (buf (get-buffer-create (concat "*notmuch-patch-" id "*"))) | |
;; (map (make-sparse-keymap))) | |
;; (evil-set-initial-state map 'normal) | |
;; (evil-define-key 'normal map "q" 'notmuch-bury-or-kill-this-buffer) | |
;; (switch-to-buffer buf) | |
;; (let ((inhibit-read-only t)) | |
;; (erase-buffer) | |
;; (insert subject) | |
;; (insert (notmuch-get-bodypart-text msg part nil))) | |
;; (set-buffer-modified-p nil) | |
;; (diff-mode) | |
;; (lexical-let ((new-ro-bind (cons 'buffer-read-only map))) | |
;; (add-to-list 'minor-mode-overriding-map-alist new-ro-bind)) | |
;; (goto-char (point-min)))) | |
;; (defun vodik/notmuch-show-view-in-browser () | |
;; "Open the HTML parts of a mail in a web browser." | |
;; (interactive) | |
;; (with-current-notmuch-show-message | |
;; (let ((mm-handle (mm-dissect-buffer))) | |
;; (notmuch-foreach-mime-part | |
;; (lambda (p) | |
;; (if (string-equal (mm-handle-media-type p) "text/html") | |
;; (mm-display-external p (lambda () | |
;; (message "Opening web browser...") | |
;; (browse-url-of-buffer) | |
;; (bury-buffer))))) | |
;; mm-handle)))) | |
;; (general-define-key | |
;; :keymaps 'notmuch-show-part-map | |
;; "s" 'notmuch-show-save-part | |
;; "v" 'notmuch-show-view-part | |
;; "o" 'notmuch-show-interactively-view-part | |
;; "|" 'notmuch-show-pipe-part | |
;; "d" 'vodik/notmuch-show-view-as-patch | |
;; "b" 'vodik/notmuch-show-view-in-browser) | |
;; ORG MODE | |
(use-package org | |
:mode ("\\.org\\'" . org-mode) | |
:general | |
("C-c c" 'counsel-org-capture) | |
:config | |
(org-babel-do-load-languages 'org-babel-load-languages '((python . t) (shell . t))) | |
:custom | |
(org-tags-column 0) | |
(org-confirm-babel-evaluate nil) | |
(org-directory "~/src/org") | |
(org-agenda-files (mapcar (lambda (path) (concat org-directory path)) | |
'("/gtd/inbox.org" | |
"/gtd/gtd.org" | |
"/gtd/tickler.org"))) | |
(org-capture-templates | |
'(("t" "Todo [inbox]" entry (file+headline "~/src/org/gtd/inbox.org" "Tasks") "* TODO %i%?") | |
("T" "Tickler" entry (file+headline "~/src/org/gtd/tickler.org" "Tickler") "* %i%? \n %^t"))) | |
(org-refile-targets | |
'(("~/src/org/gtd/gtd.org" :maxlevel . 3) | |
("~/src/org/gtd/someday.org" :level . 1) | |
("~/src/org/gtd/tickler.org" :maxlevel . 2))) | |
(org-todo-keywords | |
'((sequence "TODO(t)" "WAITING(w)" "|" "DONE(d)" "CANCELLED(c)"))) | |
(org-agenda-custom-commands | |
'(("@" "Contexts" | |
((tags-todo "@email" ((org-agenda-overriding-header "Emails"))) | |
(tags-todo "@phone" ((org-agenda-overriding-header "Phone")))))))) | |
(use-package evil-org | |
:after org | |
:diminish evil-org-mode | |
:hook ((org-mode . evil-org-mode)) | |
:config | |
(progn | |
(evil-org-set-key-theme '(navigation insert textobjects additional calendar)) | |
(require 'evil-org-agenda) | |
(evil-org-agenda-set-keys))) | |
;; (use-package ox-hugo :after ox) | |
(use-package ox-rst :after ox) | |
(use-package ox-gfm :after ox) | |
;; (use-package ob-hy | |
;; :config | |
;; (org-babel-do-load-languages 'org-babel-load-languages '((hy . t)))) | |
(use-package org-bullets | |
:commands (org-bullets-mode) | |
:init (add-hook 'org-mode-hook (lambda () (org-bullets-mode 1)))) | |
;; (use-package org-jira | |
;; :general | |
;; (:keymaps 'org-mode-map | |
;; :states 'normal | |
;; :prefix "\\" | |
;; "jpg" 'org-jira-get-projects | |
;; "jib" 'org-jira-browse-issue | |
;; "jig" 'org-jira-get-issues | |
;; "jih" 'org-jira-get-issues-headonly | |
;; "jif" 'org-jira-get-issues-from-filter-headonly | |
;; "jiF" 'org-jira-get-issues-from-filter | |
;; "jiu" 'org-jira-update-issue | |
;; "jiw" 'org-jira-progress-issue | |
;; "jir" 'org-jira-refresh-issue | |
;; "jic" 'org-jira-create-issue | |
;; "jik" 'org-jira-copy-current-issue-key | |
;; "jsc" 'org-jira-create-subtask | |
;; "jsg" 'org-jira-get-subtasks | |
;; "jcu" 'org-jira-update-comment | |
;; "jtj" 'org-jira-todo-to-jira) | |
;; :custom | |
;; (jiralib-url "https://issues.freepbx.org/")) | |
(use-package writeroom-mode | |
:commands writeroom-mode | |
:general | |
(:prefix "\\" :states 'normal "R" #'writeroom-mode)) | |
(show-paren-mode 1) | |
(setq auto-window-vscroll nil) | |
(setq ring-bell-function 'ignore) | |
(-when-let* ((browser (getenv "BROWSER")) | |
(program (executable-find browser))) | |
(setq-default browse-url-browser-function 'browse-url-generic | |
browse-url-generic-program program)) | |
(setq indent-tabs-mode nil) | |
(setq tab-always-indent 'complete) | |
(setq user-full-name "Simon Gomizelj" | |
user-mail-address "[email protected]") | |
(setq comint-move-point-for-output t) | |
(setq eshell-scroll-to-bottom-on-output t) | |
;; store all backup and autosave files in the tmp dir | |
(setq backup-directory-alist `((".*" . ,(locate-user-emacs-file "backups"))) | |
auto-save-file-name-transforms `((".*" ,temporary-file-directory t))) | |
(global-hl-line-mode t) | |
(global-auto-revert-mode t) | |
(eval-after-load 'auto-revert-mode | |
'(diminish 'auto-revert-mode)) | |
(defun vodik/fullscreen () | |
(interactive) | |
(x-send-client-message nil 0 nil "_NET_WM_STATE" 32 | |
'(2 "_NET_WM_STATE_FULLSCREEN" 0))) | |
(custom-set-variables | |
;; custom-set-variables was added by Custom. | |
;; If you edit it by hand, you could mess it up, so be careful. | |
;; Your init file should contain only one such instance. | |
;; If there is more than one, they won't work right. | |
'(airline-display-directory (quote disabled)) | |
'(airline-utf-glyph-branch 57504) | |
'(airline-utf-glyph-linenumber 57505) | |
'(airline-utf-glyph-readonly 57506) | |
'(airline-utf-glyph-separator-left 57520) | |
'(airline-utf-glyph-separator-right 57522) | |
'(airline-utf-glyph-subseparator-left 57521) | |
'(airline-utf-glyph-subseparator-right 57523) | |
'(company-frontends | |
(quote | |
(company-tng-frontend company-pseudo-tooltip-frontend company-echo-metadata-frontend))) | |
'(company-idle-delay 0.2) | |
'(company-minimum-prefix-length 1) | |
'(company-require-match nil) | |
'(company-selection-wrap-around t) | |
'(company-tooltip-align-annotations t) | |
'(counsel-git-cmd "rg --files" t) | |
'(counsel-rg-base-command | |
"rg -i -M 120 --no-heading --line-number --color never %s .") | |
'(emojify-emoji-styles (quote (github unicode)) t) | |
'(enable-recursive-minibuffers t) | |
'(evil-magit-want-horizontal-movement nil) | |
'(gnus-alias-default-identity "vodik" t) | |
'(gnus-alias-identity-alist | |
(quote | |
(("vodik" nil "Simon Gomizelj <[email protected]>" nil | |
(("Bcc" . "[email protected]")) | |
nil) | |
("sangoma" nil "Simon Gomizelj <[email protected]>" "Sangoma" | |
(("Bcc" . "[email protected]")) | |
nil))) t) | |
'(gnus-alias-identity-rules (quote (("work" ("any" "@sangoma\\.com" both) "sangoma"))) t) | |
'(gnus-alias-override-user-mail-address t t) | |
'(ivy-height 15) | |
'(ivy-use-virtual-buffers t) | |
'(linum-relative-backend (quote display-line-numbers-mode)) | |
'(linum-relative-current-symbol "") | |
'(magit-popup-show-common-commands nil) | |
'(mail-envelope-from (quote header)) | |
'(mail-host-address "vodik.xyz") | |
'(mail-interactive t) | |
'(mail-specify-envelope-from t) | |
'(message-fcc-handler-function (quote message-do-fcc)) | |
'(message-send-mail-function (quote message-send-mail-with-sendmail)) | |
'(message-sendmail-envelope-from (quote header)) | |
'(notmuch-fcc-dirs nil) | |
'(notmuch-maildir-use-notmuch-insert t) | |
'(notmuch-mua-user-agent-function (quote notmuch-mua-user-agent-full)) | |
'(notmuch-saved-searches | |
(quote | |
((:name "inbox" :query "tag:inbox" :key "i") | |
(:name "sangoma" :query "tag:sangoma" :key "s") | |
(:name "archlinux" :query "tag:archlinux" :key "a") | |
(:name "github" :query "tag:github" :key "g") | |
(:name "lists" :query "tag:lists" :key "l") | |
(:name "unread" :query "tag:unread" :key "u")))) | |
'(notmuch-search-oldest-first nil) | |
'(org-agenda-custom-commands | |
(quote | |
(("@" "Contexts" | |
((tags-todo "@email" | |
((org-agenda-overriding-header "Emails"))) | |
(tags-todo "@phone" | |
((org-agenda-overriding-header "Phone")))))))) | |
'(org-agenda-files | |
(quote | |
("~/src/org/gtd/inbox.org" "~/src/org/gtd/gtd.org" "~/src/org/gtd/tickler.org"))) | |
'(org-capture-templates | |
(quote | |
(("t" "Todo [inbox]" entry | |
(file+headline "~/src/org/gtd/inbox.org" "Tasks") | |
"* TODO %i%?") | |
("T" "Tickler" entry | |
(file+headline "~/src/org/gtd/tickler.org" "Tickler") | |
"* %i%? | |
%^t"))) t) | |
'(org-confirm-babel-evaluate nil) | |
'(org-directory "~/src/org") | |
'(org-refile-targets | |
(quote | |
(("~/src/org/gtd/gtd.org" :maxlevel . 3) | |
("~/src/org/gtd/someday.org" :level . 1) | |
("~/src/org/gtd/tickler.org" :maxlevel . 2)))) | |
'(org-tags-column 0) | |
'(org-todo-keywords | |
(quote | |
((sequence "TODO(t)" "WAITING(w)" "|" "DONE(d)" "CANCELLED(c)")))) | |
'(package-selected-packages | |
(quote | |
(gitignore-mode gitconfig-mode gitattributes-mode solaire-mode yapfify ws-butler writeroom-mode use-package toml-mode systemd stickyfunc-enhance spacemacs-theme smooth-scrolling salt-mode ranger rainbow-delimiters python-mode py-isort projectile pkgbuild-mode pipenv ox-rst org-jira org-bullets notmuch neotree monokai-theme molokai-theme material-theme markdown-mode lua-mode lispyville linum-relative json-mode hy-mode groovy-mode gnus-alias general flyspell-correct-ivy flycheck feature-mode evil-org evil-matchit evil-magit evil-goggles evil-commentary emojify elm-mode editorconfig doom-themes dockerfile-mode docker-tramp docker-compose-mode diminish cython-mode counsel company-anaconda airline-themes))) | |
'(powerline-default-separator nil) | |
'(powerline-utf-8-separator-left 57520) | |
'(powerline-utf-8-separator-right 57522) | |
'(projectile-completion-system (quote ivy)) | |
'(python-shell-interpreter "python3") | |
'(ranger-override-dired-mode t) | |
'(savehist-additional-variables (quote (search-ring regexp-search-ring))) | |
'(savehist-autosave-interval 60) | |
'(savehist-file "~/.emacs.d/savehist") | |
'(semanticdb-find-default-throttle (quote (file local project))) | |
'(sendmail-program "/usr/bin/msmtp") | |
'(smooth-scroll-margin 5) | |
'(undo-tree-auto-save-history t) | |
'(undo-tree-enable-undo-in-region nil) | |
'(undo-tree-history-directory-alist (quote ((".*" . "~/.emacs.d/undotree")))) | |
'(uniquify-buffer-name-style (quote forward) nil (uniquify)) | |
'(ws-butler-keep-whitespace-before-point nil) | |
'(ws-butler-trim-predicate | |
(quote | |
(closure | |
(t) | |
(beg end) | |
(not | |
(eq | |
(quote font-lock-string-face) | |
(get-text-property end | |
(quote face)))))))) | |
(custom-set-faces | |
;; custom-set-faces was added by Custom. | |
;; If you edit it by hand, you could mess it up, so be careful. | |
;; Your init file should contain only one such instance. | |
;; If there is more than one, they won't work right. | |
) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment