doin' a bunch of config stuff
This commit is contained in:
144
init.el
144
init.el
@@ -1,3 +1,4 @@
|
|||||||
|
;; General Config --------------------------------------------------------------
|
||||||
(setq inhibit-startup-message t) ;; turn off splash screen
|
(setq inhibit-startup-message t) ;; turn off splash screen
|
||||||
|
|
||||||
(scroll-bar-mode -1) ;; disable scroll bar
|
(scroll-bar-mode -1) ;; disable scroll bar
|
||||||
@@ -26,7 +27,8 @@
|
|||||||
;; always follow symlinks without asking
|
;; always follow symlinks without asking
|
||||||
(setq vc-follows-symlinks t
|
(setq vc-follows-symlinks t
|
||||||
find-file-visit-truename t)
|
find-file-visit-truename t)
|
||||||
;;set up package management
|
|
||||||
|
;; Package Manager -------------------------------------------------------------
|
||||||
(require 'package)
|
(require 'package)
|
||||||
|
|
||||||
(setq package-archives '(("mepla" . "https://melpa.org/packages/")
|
(setq package-archives '(("mepla" . "https://melpa.org/packages/")
|
||||||
@@ -42,14 +44,32 @@
|
|||||||
|
|
||||||
(require 'use-package)
|
(require 'use-package)
|
||||||
(setq use-package-always-ensure t)
|
(setq use-package-always-ensure t)
|
||||||
;;end package management set-up
|
|
||||||
|
|
||||||
;;theme
|
;; Style/Theme stuff ----------------------------------------------------------
|
||||||
|
;; Theme
|
||||||
(use-package gruvbox-theme
|
(use-package gruvbox-theme
|
||||||
:ensure t
|
:ensure t
|
||||||
:config
|
:config
|
||||||
(load-theme 'gruvbox-dark-hard t))
|
(load-theme 'gruvbox-dark-hard t))
|
||||||
|
|
||||||
|
|
||||||
|
;;icons are required for modeline
|
||||||
|
(use-package all-the-icons
|
||||||
|
:ensure t
|
||||||
|
:if (display-graphic-p))
|
||||||
|
|
||||||
|
;;change delimeters to different colors to help identify them
|
||||||
|
(use-package rainbow-delimiters
|
||||||
|
:hook (prod-mode . rainbow-delimiters-mode))
|
||||||
|
|
||||||
|
;; Replace the line at the bottom with something more stylish
|
||||||
|
(use-package doom-modeline
|
||||||
|
:ensure t
|
||||||
|
:init (doom-modeline-mode 1)
|
||||||
|
:config
|
||||||
|
(setq doom-modeline-height 15))
|
||||||
|
|
||||||
|
;; Completion/Search/Navigation Shenanigans -----------------------------------
|
||||||
;;completions
|
;;completions
|
||||||
(use-package vertico
|
(use-package vertico
|
||||||
:ensure t
|
:ensure t
|
||||||
@@ -85,7 +105,64 @@
|
|||||||
(use-package embark-consult
|
(use-package embark-consult
|
||||||
:ensure t)
|
:ensure t)
|
||||||
|
|
||||||
;;search across entire projects
|
(use-package which-key
|
||||||
|
:init (which-key-mode)
|
||||||
|
:diminish which-key-mode
|
||||||
|
:config
|
||||||
|
(setq which-key-idle-delay 1))
|
||||||
|
|
||||||
|
;; Key Binding Configuration ---------------------------------------------------
|
||||||
|
|
||||||
|
;; Make ESC quit prompts
|
||||||
|
(global-set-key (kbd "<escape>") 'keyboard-escape-quit)
|
||||||
|
|
||||||
|
(use-package general
|
||||||
|
:config
|
||||||
|
(general-create-definer rune/leader-keys
|
||||||
|
:keymaps '(normal insert visual emacs)
|
||||||
|
:prefix "SPC"
|
||||||
|
:global-prefix "C-SPC")
|
||||||
|
|
||||||
|
(rune/leader-keys
|
||||||
|
"t" '(:ignore t :which-key "toggles")
|
||||||
|
"tt" '(counsel-load-theme :which-key "choose theme")))
|
||||||
|
|
||||||
|
(use-package evil
|
||||||
|
:init
|
||||||
|
(setq evil-want-integration t)
|
||||||
|
(setq evil-want-keybinding nil)
|
||||||
|
(setq evil-want-C-u-scroll t)
|
||||||
|
(setq evil-want-C-i-jump nil)
|
||||||
|
:config
|
||||||
|
(evil-mode 1)
|
||||||
|
(define-key evil-insert-state-map (kbd "C-g") 'evil-normal-state)
|
||||||
|
(define-key evil-insert-state-map (kbd "C-h") 'evil-delete-backward-char-and-join)
|
||||||
|
|
||||||
|
;; Use visual line motions even outside of visual-line-mode buffers
|
||||||
|
(evil-global-set-key 'motion "j" 'evil-next-visual-line)
|
||||||
|
(evil-global-set-key 'motion "k" 'evil-previous-visual-line)
|
||||||
|
|
||||||
|
(evil-set-initial-state 'messages-buffer-mode 'normal)
|
||||||
|
(evil-set-initial-state 'dashboard-mode 'normal))
|
||||||
|
|
||||||
|
(use-package evil-collection
|
||||||
|
:after evil
|
||||||
|
:config
|
||||||
|
(evil-collection-init))
|
||||||
|
|
||||||
|
(use-package hydra)
|
||||||
|
|
||||||
|
(defhydra hydra-text-scale (:timeout 4)
|
||||||
|
"scale text"
|
||||||
|
("j" text-scale-increase "in")
|
||||||
|
("k" text-scale-decrease "out")
|
||||||
|
("f" nil "finished" :exit t))
|
||||||
|
|
||||||
|
(rh/leader-keys
|
||||||
|
"ts" '(hydra-text-scale/body :which-key "scale text"))
|
||||||
|
|
||||||
|
;; Projectile Configuration ----------------------------------------------------
|
||||||
|
|
||||||
(use-package projectile
|
(use-package projectile
|
||||||
:diminish projectile-mode
|
:diminish projectile-mode
|
||||||
:config (projectile-mode)
|
:config (projectile-mode)
|
||||||
@@ -100,26 +177,7 @@
|
|||||||
:ensure t
|
:ensure t
|
||||||
:bind (("C-c h" . consult-projectile)))
|
:bind (("C-c h" . consult-projectile)))
|
||||||
|
|
||||||
;;icons are required for modeline
|
;; Magit Configuration ---------------------------------------------------------
|
||||||
(use-package all-the-icons
|
|
||||||
:ensure t
|
|
||||||
:if (display-graphic-p))
|
|
||||||
|
|
||||||
;;replace the line at the bottom with something more stylish
|
|
||||||
(use-package doom-modeline
|
|
||||||
:ensure t
|
|
||||||
:init (doom-modeline-mode 1)
|
|
||||||
:config
|
|
||||||
(setq doom-modeline-height 15))
|
|
||||||
|
|
||||||
(use-package rainbow-delimiters
|
|
||||||
:hook (prod-mode . rainbow-delimiters-mode))
|
|
||||||
|
|
||||||
(use-package which-key
|
|
||||||
:init (which-key-mode)
|
|
||||||
:diminish which-key-mode
|
|
||||||
:config
|
|
||||||
(setq which-key-idle-delay 1))
|
|
||||||
|
|
||||||
(use-package magit
|
(use-package magit
|
||||||
:commands (magit-status magit-get-current-branch)
|
:commands (magit-status magit-get-current-branch)
|
||||||
@@ -135,6 +193,23 @@
|
|||||||
;; Use default terminal for SSH (if relevant)
|
;; Use default terminal for SSH (if relevant)
|
||||||
(magit-process-find-password-functions '(magit-process-password-auth-source)))
|
(magit-process-find-password-functions '(magit-process-password-auth-source)))
|
||||||
|
|
||||||
|
(use-package evil-magit
|
||||||
|
:after magit)
|
||||||
|
|
||||||
|
;; IDK what this stuff is but it shows up automatically ------------------------
|
||||||
|
(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.
|
||||||
|
'(package-selected-packages nil))
|
||||||
|
(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.
|
||||||
|
)
|
||||||
|
|
||||||
;; Org Mode Configuration ------------------------------------------------------
|
;; Org Mode Configuration ------------------------------------------------------
|
||||||
|
|
||||||
(defun rh/org-mode-setup ()
|
(defun rh/org-mode-setup ()
|
||||||
@@ -142,6 +217,7 @@
|
|||||||
(variable-pitch-mode 1)
|
(variable-pitch-mode 1)
|
||||||
(visual-line-mode 1))
|
(visual-line-mode 1))
|
||||||
|
|
||||||
|
|
||||||
(defun rh/org-font-setup ()
|
(defun rh/org-font-setup ()
|
||||||
;; Replace list hyphen with dot
|
;; Replace list hyphen with dot
|
||||||
(font-lock-add-keywords 'org-mode
|
(font-lock-add-keywords 'org-mode
|
||||||
@@ -172,7 +248,7 @@
|
|||||||
:hook (org-mode . rh/org-mode-setup)
|
:hook (org-mode . rh/org-mode-setup)
|
||||||
:config
|
:config
|
||||||
(setq org-ellipsis " ▾")
|
(setq org-ellipsis " ▾")
|
||||||
(rh/org-font-setup))
|
(efs/org-font-setup))
|
||||||
|
|
||||||
(use-package org-bullets
|
(use-package org-bullets
|
||||||
:after org
|
:after org
|
||||||
@@ -186,20 +262,4 @@
|
|||||||
(visual-fill-column-mode 1))
|
(visual-fill-column-mode 1))
|
||||||
|
|
||||||
(use-package visual-fill-column
|
(use-package visual-fill-column
|
||||||
:hook (org-mode . efs/org-mode-visual-fill))
|
:hook (org-mode . rh/org-mode-visual-fill))
|
||||||
(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.
|
|
||||||
'(package-selected-packages
|
|
||||||
'(all-the-icons consult-projectile doom-modeline embark-consult
|
|
||||||
gruvbox-theme magit marginalia orderless
|
|
||||||
org-bullets rainbow-delimiters vertico
|
|
||||||
visual-fill-column)))
|
|
||||||
(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.
|
|
||||||
)
|
|
||||||
|
|||||||
Reference in New Issue
Block a user