General cleanup
This commit is contained in:
parent
ea13be53b1
commit
eaa467c1a7
12 changed files with 18 additions and 20 deletions
|
@ -190,8 +190,8 @@ Examples:
|
||||||
(after! evil
|
(after! evil
|
||||||
(defalias 'ex! 'evil-ex-define-cmd)
|
(defalias 'ex! 'evil-ex-define-cmd)
|
||||||
|
|
||||||
;; NOTE evil-mode doesn't read local `evil-ex-commands', and will
|
;; NOTE evil-mode doesn't read local `evil-ex-commands', and will not
|
||||||
;; not autocomplete local commands.
|
;; autocomplete local commands.
|
||||||
(defun ex-local! (cmd fn)
|
(defun ex-local! (cmd fn)
|
||||||
"Define a buffer-local ex command."
|
"Define a buffer-local ex command."
|
||||||
(unless (local-variable-p 'evil-ex-commands)
|
(unless (local-variable-p 'evil-ex-commands)
|
||||||
|
|
|
@ -63,7 +63,6 @@
|
||||||
:n "k" 'evil-previous-line
|
:n "k" 'evil-previous-line
|
||||||
:n "h" 'evil-backward-char
|
:n "h" 'evil-backward-char
|
||||||
:n "l" 'evil-forward-char
|
:n "l" 'evil-forward-char
|
||||||
;; FIXME Greedy command buffer always grabs focus
|
|
||||||
:m "n" 'realgud:cmd-next
|
:m "n" 'realgud:cmd-next
|
||||||
:m "b" 'realgud:cmd-break
|
:m "b" 'realgud:cmd-break
|
||||||
:m "B" 'realgud:cmd-clear
|
:m "B" 'realgud:cmd-clear
|
||||||
|
|
|
@ -97,9 +97,8 @@
|
||||||
:init (add-hook! (prog-mode markdown-mode) 'hl-line-mode)
|
:init (add-hook! (prog-mode markdown-mode) 'hl-line-mode)
|
||||||
:config
|
:config
|
||||||
;; Doesn't seem to play nice in emacs 25+
|
;; Doesn't seem to play nice in emacs 25+
|
||||||
(when (< emacs-major-version 25)
|
(setq hl-line-sticky-flag nil
|
||||||
(setq hl-line-sticky-flag nil
|
global-hl-line-sticky-flag nil)
|
||||||
global-hl-line-sticky-flag nil))
|
|
||||||
|
|
||||||
(defvar-local doom--hl-line-mode nil)
|
(defvar-local doom--hl-line-mode nil)
|
||||||
(defun doom|hl-line-on () (if doom--hl-line-mode (hl-line-mode +1)))
|
(defun doom|hl-line-on () (if doom--hl-line-mode (hl-line-mode +1)))
|
||||||
|
@ -394,9 +393,11 @@ anzu to be enabled."
|
||||||
'doom-flycheck-warning
|
'doom-flycheck-warning
|
||||||
'mode-line))))))))))
|
'mode-line))))))))))
|
||||||
|
|
||||||
|
(defvar *pad-active (pl/percent-xpm powerline-height 100 0 100 0 3 "#00B3EF" nil))
|
||||||
|
(defvar *pad-inactive (pl/percent-xpm powerline-height 100 0 100 0 3 nil nil))
|
||||||
(spaceline-define-segment *pad
|
(spaceline-define-segment *pad
|
||||||
"Padding, to ensure the mode-line is `powerline-height' pixels tall"
|
"Padding, to ensure the mode-line is `powerline-height' pixels tall"
|
||||||
(pl/percent-xpm powerline-height 100 0 100 0 3 (if active "#00B3EF") nil)
|
(if active *pad-active *pad-inactive)
|
||||||
:tight t)
|
:tight t)
|
||||||
|
|
||||||
(spaceline-compile
|
(spaceline-compile
|
||||||
|
@ -441,9 +442,10 @@ anzu to be enabled."
|
||||||
:tight t
|
:tight t
|
||||||
:face 'mode-line)
|
:face 'mode-line)
|
||||||
|
|
||||||
|
(defvar *eldoc-pad-xpm (pl/percent-xpm powerline-height 100 0 100 0 3 "#B3EF00" nil))
|
||||||
(spaceline-define-segment *eldoc-pad
|
(spaceline-define-segment *eldoc-pad
|
||||||
"Padding, to ensure the mode-line is `powerline-height' pixels tall"
|
"Padding, to ensure the mode-line is `powerline-height' pixels tall"
|
||||||
(pl/percent-xpm powerline-height 100 0 100 0 3 "#B3EF00" nil)
|
*eldoc-pad-xpm
|
||||||
:tight t
|
:tight t
|
||||||
:face 'mode-line)
|
:face 'mode-line)
|
||||||
|
|
||||||
|
|
|
@ -68,6 +68,7 @@
|
||||||
(select-window (get-buffer-window doom-prev-buffer)))
|
(select-window (get-buffer-window doom-prev-buffer)))
|
||||||
(switch-to-buffer b)))
|
(switch-to-buffer b)))
|
||||||
|
|
||||||
|
;; Prevent magit and evil-snipe conflicts
|
||||||
(add-hook 'magit-mode-hook 'turn-off-evil-snipe-override-mode)
|
(add-hook 'magit-mode-hook 'turn-off-evil-snipe-override-mode)
|
||||||
|
|
||||||
(require 'evil-magit)
|
(require 'evil-magit)
|
||||||
|
|
|
@ -43,9 +43,7 @@
|
||||||
;; Strip out whitespace before a line selection
|
;; Strip out whitespace before a line selection
|
||||||
(add-hook 'yas-before-expand-snippet-hook 'doom|yas-before-expand)
|
(add-hook 'yas-before-expand-snippet-hook 'doom|yas-before-expand)
|
||||||
;; Fix previous hook persisting yas-selected-text between expansions
|
;; Fix previous hook persisting yas-selected-text between expansions
|
||||||
(add-hook 'yas-after-exit-snippet-hook 'doom|yas-after-expand)
|
(add-hook 'yas-after-exit-snippet-hook 'doom|yas-after-expand))
|
||||||
;; Suppress yasnippet with helm
|
|
||||||
(after! helm (push 'helm-alive-p yas-dont-activate-functions)))
|
|
||||||
|
|
||||||
(use-package auto-yasnippet
|
(use-package auto-yasnippet
|
||||||
:commands (aya-create aya-expand aya-open-line aya-persist-snippet)
|
:commands (aya-create aya-expand aya-open-line aya-persist-snippet)
|
||||||
|
|
|
@ -144,7 +144,6 @@ the display (unless DONT-REDRAW is non-nil)."
|
||||||
doom-popup-rules))))
|
doom-popup-rules))))
|
||||||
(setq doom-last-popup (current-buffer))
|
(setq doom-last-popup (current-buffer))
|
||||||
(setq-local doom-popup-rule rules)
|
(setq-local doom-popup-rule rules)
|
||||||
;; (set-window-dedicated-p (selected-window) doom-popup-mode)
|
|
||||||
(unless (memq :noesc rules)
|
(unless (memq :noesc rules)
|
||||||
(make-local-variable 'doom-popup-mode-map)
|
(make-local-variable 'doom-popup-mode-map)
|
||||||
(let ((map doom-popup-mode-map))
|
(let ((map doom-popup-mode-map))
|
||||||
|
|
|
@ -45,7 +45,7 @@
|
||||||
:config
|
:config
|
||||||
(setq irony-server-install-prefix (concat doom-temp-dir "/irony/"))
|
(setq irony-server-install-prefix (concat doom-temp-dir "/irony/"))
|
||||||
(add-hook! c++-mode
|
(add-hook! c++-mode
|
||||||
(make-variable-buffer-local 'irony-additional-clang-options)
|
(make-local-variable 'irony-additional-clang-options)
|
||||||
(push "-std=c++11" irony-additional-clang-options))
|
(push "-std=c++11" irony-additional-clang-options))
|
||||||
|
|
||||||
(require 'irony-eldoc)
|
(require 'irony-eldoc)
|
||||||
|
|
|
@ -12,7 +12,7 @@
|
||||||
(setq omnisharp-auto-complete-want-documentation nil
|
(setq omnisharp-auto-complete-want-documentation nil
|
||||||
omnisharp-server-executable-path (concat doom-ext-dir "/OmniSharp.exe"))
|
omnisharp-server-executable-path (concat doom-ext-dir "/OmniSharp.exe"))
|
||||||
:when (file-exists-p omnisharp-server-executable-path)
|
:when (file-exists-p omnisharp-server-executable-path)
|
||||||
:init (add-hook! csharp-mode '(turn-on-eldoc-mode omnisharp-mode))
|
:init (add-hook! csharp-mode '(eldoc-mode omnisharp-mode))
|
||||||
:config
|
:config
|
||||||
(def-company-backend! csharp-mode (omnisharp))
|
(def-company-backend! csharp-mode (omnisharp))
|
||||||
(map! :map omnisharp-mode-map
|
(map! :map omnisharp-mode-map
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
;;; module-elisp --- all things lisp
|
;;; module-elisp --- all things lisp
|
||||||
|
|
||||||
(associate! emacs-lisp-mode :match "\\(/Cask\\|\\.\\(el\\|gz\\)\\)$")
|
(associate! emacs-lisp-mode :match "\\(/Cask\\|\\.\\(el\\|gz\\)\\)$")
|
||||||
(add-hook! emacs-lisp-mode '(turn-on-eldoc-mode flycheck-mode highlight-numbers-mode))
|
(add-hook! emacs-lisp-mode '(eldoc-mode flycheck-mode highlight-numbers-mode))
|
||||||
|
|
||||||
;; Real go-to-definition for elisp
|
;; Real go-to-definition for elisp
|
||||||
(map! :map emacs-lisp-mode-map :m "gd" 'doom/elisp-find-function-at-pt)
|
(map! :map emacs-lisp-mode-map :m "gd" 'doom/elisp-find-function-at-pt)
|
||||||
|
@ -103,11 +103,10 @@
|
||||||
:config (setq inferior-lisp-program "clisp"))
|
:config (setq inferior-lisp-program "clisp"))
|
||||||
|
|
||||||
(use-package auto-compile
|
(use-package auto-compile
|
||||||
:commands (auto-compile-on-save-mode)
|
:commands auto-compile-on-save-mode
|
||||||
:init (add-hook 'emacs-lisp-mode-hook 'auto-compile-on-save-mode)
|
:init (add-hook 'emacs-lisp-mode-hook 'auto-compile-on-save-mode)
|
||||||
:config (setq auto-compile-display-buffer nil))
|
:config (setq auto-compile-display-buffer nil))
|
||||||
|
|
||||||
|
|
||||||
;;
|
;;
|
||||||
(def-project-type! emacs-ert "ert"
|
(def-project-type! emacs-ert "ert"
|
||||||
:modes (emacs-lisp-mode)
|
:modes (emacs-lisp-mode)
|
||||||
|
|
|
@ -29,7 +29,7 @@
|
||||||
|
|
||||||
(use-package php-extras
|
(use-package php-extras
|
||||||
:after php-mode
|
:after php-mode
|
||||||
:init (add-hook 'php-mode-hook 'turn-on-eldoc-mode)
|
:init (add-hook 'php-mode-hook 'eldoc-mode)
|
||||||
:config
|
:config
|
||||||
(defun php-extras-company-setup ()) ;; company will set up itself
|
(defun php-extras-company-setup ()) ;; company will set up itself
|
||||||
;; Generate php-extras documentation and completion asynchronously
|
;; Generate php-extras documentation and completion asynchronously
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
(use-package scala-mode
|
(use-package scala-mode
|
||||||
:mode "\\.s\\(cala\\|bt\\)$"
|
:mode "\\.s\\(cala\\|bt\\)$"
|
||||||
:init (add-hook 'scala-mode-hook 'turn-on-eldoc-mode)
|
:init (add-hook 'scala-mode-hook 'eldoc-mode)
|
||||||
:config (def-company-backend! scala-mode '(ensime-company (company-yasnippet))))
|
:config (def-company-backend! scala-mode '(ensime-company (company-yasnippet))))
|
||||||
|
|
||||||
(use-package sbt-mode
|
(use-package sbt-mode
|
||||||
|
|
|
@ -6,7 +6,7 @@
|
||||||
:mode ("\\.m\\(d\\|arkdown\\)$" "/README$"
|
:mode ("\\.m\\(d\\|arkdown\\)$" "/README$"
|
||||||
("/README\\.md$" . gfm-mode))
|
("/README\\.md$" . gfm-mode))
|
||||||
:init
|
:init
|
||||||
(add-hook 'markdown-mode-hook 'turn-on-auto-fill)
|
(add-hook 'markdown-mode-hook 'auto-fill-mode)
|
||||||
(setq markdown-enable-wiki-links t
|
(setq markdown-enable-wiki-links t
|
||||||
markdown-italic-underscore t
|
markdown-italic-underscore t
|
||||||
markdown-enable-math t
|
markdown-enable-math t
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue