From fb3cd91e4d9b4f699338546a447b5f946c0624de Mon Sep 17 00:00:00 2001 From: Alan Pearce Date: Mon, 29 Jun 2020 15:32:32 +0200 Subject: Reformat emacs init file --- user/emacs/init.el | 138 ++++++++++++++++++++++++++--------------------------- 1 file changed, 69 insertions(+), 69 deletions(-) diff --git a/user/emacs/init.el b/user/emacs/init.el index 626cf041..ff3b640d 100644 --- a/user/emacs/init.el +++ b/user/emacs/init.el @@ -58,7 +58,7 @@ ;;; Styles - ;; I prefer an always-visible cursor. Feels less distracting. +;; I prefer an always-visible cursor. Feels less distracting. (blink-cursor-mode -1) ;; Disable all the bars, unless on OSX, in which case, keep the menu bar. (unless (eq system-type 'darwin) @@ -75,7 +75,7 @@ (ding)))) (when (or (daemonp) - window-system) + window-system) (use-package almost-mono-themes :config (load-theme 'almost-mono-white t)) (if (eq window-system 'x) @@ -144,7 +144,7 @@ With two prefix arguments, write out the day and month name." (use-package general :functions (general-unbind general-define-key) :config (progn - (general-override-mode +1) + (general-override-mode +1) (when (eq system-type 'darwin) (general-unbind "s-x")))) @@ -211,9 +211,9 @@ _p_rev _u_pper _=_: upper/lower _r_esolve ("r" smerge-resolve) ("k" smerge-kill-current) ("w" (lambda () - (interactive) - (save-buffer) - (bury-buffer)) + (interactive) + (save-buffer) + (bury-buffer)) "Save and bury buffer" :color blue) ("q" nil "cancel" :color blue)) :hook (magit-diff-visit-file . (lambda () @@ -235,15 +235,15 @@ _p_rev _u_pper _=_: upper/lower _r_esolve ;;; Windows (defun split-window-properly (&optional window) - (let ((window (or window (selected-window)))) + (let ((window (or window (selected-window)))) (or (and (window-splittable-p window) - ;; Split window vertically. - (with-selected-window window - (split-window-below))) - (and (window-splittable-p window t) - ;; Split window horizontally. - (with-selected-window window - (split-window-right)))))) + ;; Split window vertically. + (with-selected-window window + (split-window-below))) + (and (window-splittable-p window t) + ;; Split window horizontally. + (with-selected-window window + (split-window-right)))))) (setq split-window-preferred-function #'split-window-properly split-height-threshold 20 @@ -278,9 +278,9 @@ _p_rev _u_pper _=_: upper/lower _r_esolve (setq winner-boring-buffers '("*Completions*" "*Help*" "*Apropos*" "*Buffer List*" "*info*" "*Compile-Log*")) (winner-mode +1)) :general (:keymaps 'evil-window-map - "u" #'winner-undo - "r" #'winner-redo - "C-r" #'winner-redo)) + "u" #'winner-undo + "r" #'winner-redo + "C-r" #'winner-redo)) ;;; Evil (use-package evil @@ -294,9 +294,9 @@ _p_rev _u_pper _=_: upper/lower _r_esolve (evil-mode +1)) :general (:states 'motion - "C-;" #'evil-avy-goto-line) + "C-;" #'evil-avy-goto-line) (:states 'normal - ";" #'evil-ex) + ";" #'evil-ex) (:states '(normal motion) "g s" #'evil-avy-goto-symbol-1)) @@ -311,7 +311,7 @@ _p_rev _u_pper _=_: upper/lower _r_esolve :demand t :commands (evil-collection-init) :config (progn - (evil-collection-init))) + (evil-collection-init))) (general-create-definer my-leader-def :keymaps 'override @@ -413,16 +413,16 @@ _p_rev _u_pper _=_: upper/lower _r_esolve projectile-root-bottom-up projectile-root-top-down-recurring)) (projectile-mode +1) - (with-eval-after-load 'evil-ex + (with-eval-after-load 'evil-ex (evil-ex-define-cmd "rg" #'ripgrep-regexp) - (evil-ex-define-cmd "prg" #'projectile-ripgrep) + (evil-ex-define-cmd "prg" #'projectile-ripgrep) (evil-ex-define-cmd "pesh[ell]" #'projectile-run-eshell)))) (use-package counsel-projectile :defer 1 :commands (counsel-projectile-switch-project - counsel-projectile-rg - counsel-projectile-switch-to-buffer + counsel-projectile-rg + counsel-projectile-switch-to-buffer counsel-projectile-mode) :general (:keymaps 'projectile-command-map "s s" #'counsel-projectile-rg @@ -430,10 +430,10 @@ _p_rev _u_pper _=_: upper/lower _r_esolve :config (progn (assq-delete-all #'projectile-ripgrep counsel-projectile-key-bindings) (counsel-projectile-mode +1) - (with-eval-after-load 'evil-ex - (evil-ex-define-cmd "cprg" #'counsel-projectile-rg) - (evil-ex-define-cmd "pb" #'counsel-projectile-switch-to-buffer) - (evil-ex-define-cmd "psw[itch]" #'counsel-projectile-switch-project)))) + (with-eval-after-load 'evil-ex + (evil-ex-define-cmd "cprg" #'counsel-projectile-rg) + (evil-ex-define-cmd "pb" #'counsel-projectile-switch-to-buffer) + (evil-ex-define-cmd "psw[itch]" #'counsel-projectile-switch-project)))) (use-package magit :defer 10 @@ -732,8 +732,8 @@ _p_rev _u_pper _=_: upper/lower _r_esolve ;;;; gitlab-ci.yml (with-eval-after-load 'git-gutter-fringe - (fringe-helper-define 'flycheck-fringe-bitmap-double-arrow '(center repeated) - "XXX.....")) + (fringe-helper-define 'flycheck-fringe-bitmap-double-arrow '(center repeated) + "XXX.....")) (setq gitlab-ci-url "https://gitlab.satoshipay.tech") (use-package gitlab-ci-mode-flycheck @@ -770,9 +770,9 @@ _p_rev _u_pper _=_: upper/lower _r_esolve (format-time-string "%Y-%m-%d" (time-add (current-time) (days-to-time -180))))) ("Expenses:This Month" "ledger -f %(ledger-file) register \\^Expenses -p \"this month\"") ("Expenses:Past 90 Days (monthly)" ,(concat "ledger -f %(ledger-file) register --monthly ^Expenses -b " - (format-time-string "%Y-%m-%d" (time-add (current-time) (days-to-time -90))))) + (format-time-string "%Y-%m-%d" (time-add (current-time) (days-to-time -90))))) ("Expenses:Past 180 Days (monthly)" ,(concat "ledger -f %(ledger-file) register --monthly ^Expenses -b " - (format-time-string "%Y-%m-%d" (time-add (current-time) (days-to-time -180))))) + (format-time-string "%Y-%m-%d" (time-add (current-time) (days-to-time -180))))) ("All Account Balances" "ledger -f %(ledger-file) bal --current -R \\^Assets \\^Liabilities"))))) @@ -788,8 +788,8 @@ _p_rev _u_pper _=_: upper/lower _r_esolve (use-package org-journal :after org :commands (org-journal-new-date-entry - org-journal-new-entry - org-journal-new-scheduled-entry) + org-journal-new-entry + org-journal-new-scheduled-entry) :gfhook (#'variable-pitch-mode) :config (setq org-journal-date-format "%A, %d %B %Y" org-journal-dir "~/Documents/journal")) @@ -977,41 +977,41 @@ _p_rev _u_pper _=_: upper/lower _r_esolve ;;; Take me to my leader (my-leader-def - "" nil - "`" #'eshell-toggle - "h" '(:keymap ehelp-map :package ehelp) - "w" '(:keymap evil-window-map :package evil) - "x" '(:keymap ctl-x-map) - "c" (general-simulate-key "C-c") - "l" '(:keymap lsp-command-map :package lsp-mode) - "q" #'evil-delete-buffer - "p" '(:keymap projectile-command-map :package projectile) - "v" #'split-window-right - "o" #'other-window - "u" #'universal-argument - ";" #'counsel-M-x - "bb" #'counsel-switch-buffer - "bx" #'kill-this-buffer - "br" #'revert-buffer - "bk" #'kill-buffer - "dd" #'dired - "fs" #'save-buffer - "ff" #'find-file - "fw" #'write-file - "fd" #'delete-file - "fr" #'crux-rename-file-and-buffer - "gs" #'magit-status - "gm" #'git-messenger:popup-message - "gg" #'magit-dispatch - "gn" #'git-gutter:next-hunk - "gp" #'git-gutter:previous-hunk - "gi" #'git-gutter:popup-hunk - "gs" #'git-gutter:stage-hunk - "go" #'git-gutter:revert-hunk - "gt" #'git-timemachine - "bi" #'ibuffer - "bz" #'bury-buffer - "iu" #'counsel-unicode-char) + "" nil + "`" #'eshell-toggle + "h" '(:keymap ehelp-map :package ehelp) + "w" '(:keymap evil-window-map :package evil) + "x" '(:keymap ctl-x-map) + "c" (general-simulate-key "C-c") + "l" '(:keymap lsp-command-map :package lsp-mode) + "q" #'evil-delete-buffer + "p" '(:keymap projectile-command-map :package projectile) + "v" #'split-window-right + "o" #'other-window + "u" #'universal-argument + ";" #'counsel-M-x + "bb" #'counsel-switch-buffer + "bx" #'kill-this-buffer + "br" #'revert-buffer + "bk" #'kill-buffer + "dd" #'dired + "fs" #'save-buffer + "ff" #'find-file + "fw" #'write-file + "fd" #'delete-file + "fr" #'crux-rename-file-and-buffer + "gs" #'magit-status + "gm" #'git-messenger:popup-message + "gg" #'magit-dispatch + "gn" #'git-gutter:next-hunk + "gp" #'git-gutter:previous-hunk + "gi" #'git-gutter:popup-hunk + "gs" #'git-gutter:stage-hunk + "go" #'git-gutter:revert-hunk + "gt" #'git-timemachine + "bi" #'ibuffer + "bz" #'bury-buffer + "iu" #'counsel-unicode-char) (load (expand-file-name "mail.el" user-emacs-directory) :noerror) -- cgit 1.4.1