General cleanup & minor refactoring
This commit is contained in:
parent
b6f4fe667a
commit
4910531457
5 changed files with 12 additions and 12 deletions
|
@ -1,7 +1,6 @@
|
||||||
;;; core-editor.el --- filling the editor shaped hole in the Emacs OS
|
;;; core-editor.el --- filling the editor shaped hole in the Emacs OS
|
||||||
|
|
||||||
(setq-default
|
(setq-default
|
||||||
shift-select-mode t ; activate mark on shift-click
|
|
||||||
;; Save clipboard contents into kill-ring before replacing them
|
;; Save clipboard contents into kill-ring before replacing them
|
||||||
save-interprogram-paste-before-kill t
|
save-interprogram-paste-before-kill t
|
||||||
;; Bookmarks
|
;; Bookmarks
|
||||||
|
@ -38,8 +37,7 @@
|
||||||
;; Save point across sessions
|
;; Save point across sessions
|
||||||
(require 'saveplace)
|
(require 'saveplace)
|
||||||
(setq save-place-file (concat doom-cache-dir "saveplace"))
|
(setq save-place-file (concat doom-cache-dir "saveplace"))
|
||||||
(when (>= emacs-major-version 25)
|
(save-place-mode +1)
|
||||||
(save-place-mode +1))
|
|
||||||
|
|
||||||
;; Save history across sessions
|
;; Save history across sessions
|
||||||
(require 'savehist)
|
(require 'savehist)
|
||||||
|
|
|
@ -106,6 +106,8 @@ are installed. If you byte-compile core/core.el, this function will be avoided
|
||||||
to speed up startup."
|
to speed up startup."
|
||||||
;; Called early during initialization; only use native functions!
|
;; Called early during initialization; only use native functions!
|
||||||
(unless (or doom-init-p force-p)
|
(unless (or doom-init-p force-p)
|
||||||
|
(message "Doom initialized")
|
||||||
|
|
||||||
(setq load-path doom--base-load-path
|
(setq load-path doom--base-load-path
|
||||||
package-activated-list nil)
|
package-activated-list nil)
|
||||||
|
|
||||||
|
@ -123,7 +125,7 @@ to speed up startup."
|
||||||
;; Also, in some edge cases involving package initialization during a
|
;; Also, in some edge cases involving package initialization during a
|
||||||
;; non-interactive session, `package-initialize' fails to fill `load-path'.
|
;; non-interactive session, `package-initialize' fails to fill `load-path'.
|
||||||
;; If we want something done right, do it ourselves!
|
;; If we want something done right, do it ourselves!
|
||||||
(setq load-path (append load-path (directory-files package-user-dir t "^[a-zA-Z0-9]" t)))
|
(setq load-path (append load-path (directory-files package-user-dir t "^\\w" t)))
|
||||||
|
|
||||||
;; Ensure core packages are installed
|
;; Ensure core packages are installed
|
||||||
(let ((core-packages (cl-remove-if 'package-installed-p doom-protected-packages)))
|
(let ((core-packages (cl-remove-if 'package-installed-p doom-protected-packages)))
|
||||||
|
@ -170,7 +172,6 @@ files."
|
||||||
(append (reverse (file-expand-wildcards (concat doom-core-dir "core*.el")))
|
(append (reverse (file-expand-wildcards (concat doom-core-dir "core*.el")))
|
||||||
(file-expand-wildcards (concat doom-core-dir "autoload/*.el"))
|
(file-expand-wildcards (concat doom-core-dir "autoload/*.el"))
|
||||||
(doom--module-paths "config.el")))))
|
(doom--module-paths "config.el")))))
|
||||||
|
|
||||||
(when (or force-p (not doom-packages))
|
(when (or force-p (not doom-packages))
|
||||||
(setq doom-packages nil)
|
(setq doom-packages nil)
|
||||||
(funcall load-fn (expand-file-name "packages.el" doom-core-dir))
|
(funcall load-fn (expand-file-name "packages.el" doom-core-dir))
|
||||||
|
|
|
@ -35,7 +35,10 @@
|
||||||
evil-ex-search-vim-style-regexp t
|
evil-ex-search-vim-style-regexp t
|
||||||
evil-ex-substitute-global t
|
evil-ex-substitute-global t
|
||||||
evil-ex-visual-char-range t ; column range for ex commands
|
evil-ex-visual-char-range t ; column range for ex commands
|
||||||
evil-insert-skip-empty-lines t)
|
evil-insert-skip-empty-lines t
|
||||||
|
|
||||||
|
;; don't activate mark on shift-click
|
||||||
|
shift-select-mode nil)
|
||||||
|
|
||||||
:config
|
:config
|
||||||
(evil-mode +1)
|
(evil-mode +1)
|
||||||
|
@ -58,8 +61,6 @@
|
||||||
(add-hook 'evil-operator-state-entry-hook 'show-paren-mode)
|
(add-hook 'evil-operator-state-entry-hook 'show-paren-mode)
|
||||||
(add-hook 'evil-operator-state-exit-hook '+evil|show-paren-mode-off)
|
(add-hook 'evil-operator-state-exit-hook '+evil|show-paren-mode-off)
|
||||||
(add-hook 'evil-normal-state-entry-hook '+evil|show-paren-mode-off)
|
(add-hook 'evil-normal-state-entry-hook '+evil|show-paren-mode-off)
|
||||||
;; Disable highlights on insert-mode
|
|
||||||
;; (add-hook 'evil-insert-state-entry-hook 'evil-ex-nohighlight)
|
|
||||||
|
|
||||||
(@set :popup
|
(@set :popup
|
||||||
'("*evil-registers*" :size 0.3)
|
'("*evil-registers*" :size 0.3)
|
||||||
|
|
|
@ -39,9 +39,7 @@
|
||||||
|
|
||||||
|
|
||||||
;;
|
;;
|
||||||
(setq initial-major-mode '+doom-dashboard-mode
|
(setq doom-fallback-buffer +doom-dashboard-name)
|
||||||
initial-scratch-message "\n Loading..."
|
|
||||||
doom-fallback-buffer +doom-dashboard-name)
|
|
||||||
|
|
||||||
(add-hook 'emacs-startup-hook '+doom-dashboard/open)
|
(add-hook 'emacs-startup-hook '+doom-dashboard/open)
|
||||||
(@add-hook 'kill-buffer-query-functions
|
(@add-hook 'kill-buffer-query-functions
|
||||||
|
@ -62,7 +60,7 @@
|
||||||
|
|
||||||
;;
|
;;
|
||||||
(defun +doom-dashboard/open ()
|
(defun +doom-dashboard/open ()
|
||||||
""
|
"Open the dashboard buffer."
|
||||||
(interactive)
|
(interactive)
|
||||||
(+doom-dashboard-reload)
|
(+doom-dashboard-reload)
|
||||||
(switch-to-buffer (doom-fallback-buffer)))
|
(switch-to-buffer (doom-fallback-buffer)))
|
||||||
|
|
|
@ -1,5 +1,7 @@
|
||||||
;;; ui/doom-modeline/config.el
|
;;; ui/doom-modeline/config.el
|
||||||
|
|
||||||
|
(line-number-mode -1)
|
||||||
|
|
||||||
;; all-the-icons doesn't work in the terminal, so we "disable" it.
|
;; all-the-icons doesn't work in the terminal, so we "disable" it.
|
||||||
(unless (display-graphic-p)
|
(unless (display-graphic-p)
|
||||||
(defalias 'all-the-icons-octicon 'ignore)
|
(defalias 'all-the-icons-octicon 'ignore)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue