aboutsummaryrefslogtreecommitdiffstats
path: root/emacs/.emacs.d/init.org
diff options
context:
space:
mode:
authorGravatar Tom Willemse2026-06-10 16:52:56 -0700
committerGravatar Tom Willemse2026-06-10 16:55:34 -0700
commitcb73a736736c8091697f93e62c31502bed9ccf80 (patch)
treea9b9c381f59517e9d747c37c1ccc416644b37a24 /emacs/.emacs.d/init.org
parenta61c4330a203ff71b0418e6638925754b4d16d54 (diff)
downloadnew-dotfiles-cb73a736736c8091697f93e62c31502bed9ccf80.tar.gz
new-dotfiles-cb73a736736c8091697f93e62c31502bed9ccf80.zip
Update Emacs config
This is mainly used by my work machine at the moment, but that should change soon.
Diffstat (limited to 'emacs/.emacs.d/init.org')
-rw-r--r--emacs/.emacs.d/init.org95
1 files changed, 50 insertions, 45 deletions
diff --git a/emacs/.emacs.d/init.org b/emacs/.emacs.d/init.org
index 676a671..8972f65 100644
--- a/emacs/.emacs.d/init.org
+++ b/emacs/.emacs.d/init.org
@@ -66,18 +66,38 @@ So now that that's settled, I should be writing ='= in words like “shouldn't''
Add MELPA to package archives, this lets me install more packages.
#+begin_src emacs-lisp
- (use-package package
- :config
- (add-to-list 'package-archives '("melpa" . "https://melpa.org/packages/") t))
+ (eval-and-compile
+ (use-package package
+ :config
+ (add-to-list 'package-archives '("melpa" . "https://melpa.org/packages/") t)))
+#+end_src
+
+Make use-package default to ensuring everything. This way each =use-package= doesn't need to have its own ~:ensure t~ and when I use Guix to install these modules they don't try to download everything from everywhere else.
+
+#+begin_src emacs-lisp
+ (eval-and-compile
+ (require 'use-package-ensure)
+ (setq use-package-always-ensure t))
+#+end_src
+
+* exec-path-from-shell
+
+This is necessary to make sure that packages installed through bundle and such are available in Emacs.
+
+#+begin_src emacs-lisp
+ (use-package exec-path-from-shell
+ :init
+ (when (memq window-system '(mac ns x))
+ (exec-path-from-shell-initialize)))
#+end_src
+* Ensure system packages
+
Add the =use-package-ensure-system-package= extension for =use-package=.
#+begin_src emacs-lisp
(use-package use-package-ensure-system-package)
-
- (use-package system-packages
- :ensure t)
+ (use-package system-packages)
#+end_src
* Docker
@@ -85,8 +105,7 @@ Add the =use-package-ensure-system-package= extension for =use-package=.
I need to use Docker for some projects at work.
#+begin_src emacs-lisp
- (use-package dockerfile-mode
- :ensure t)
+ (use-package dockerfile-mode)
#+end_src
* PHP
@@ -95,7 +114,6 @@ I currently develop in PHP.
#+begin_src emacs-lisp
(use-package php-mode
- :ensure t
:ensure-system-package php)
#+end_src
@@ -105,7 +123,6 @@ GIT.
#+begin_src emacs-lisp
(use-package magit
- :ensure t
:hook
(magit-pre-display-buffer-hook . magit-save-window-configuration)
:custom
@@ -126,27 +143,13 @@ Tell magit to apply ANSI colors in the process buffer.
Lua is mainly used by wezterm right now.
#+begin_src emacs-lisp
- (use-package lua-mode
- :ensure t)
-#+end_src
-
-* exec-path-from-shell
-
-This is necessary to make sure that packages installed through bundle and such are available in Emacs.
-
-#+begin_src emacs-lisp
- (use-package exec-path-from-shell
- :ensure t
- :init
- (when (memq window-system '(mac ns x))
- (exec-path-from-shell-initialize)))
+ (use-package lua-mode)
#+end_src
* Markdown
#+begin_src emacs-lisp
- (use-package markdown-mode
- :ensure t)
+ (use-package markdown-mode)
#+end_src
* Org Mode
@@ -197,8 +200,7 @@ This is necessary to make sure that packages installed through bundle and such a
This is used to hide minor mode names.
#+begin_src emacs-lisp
- (use-package diminish
- :ensure t)
+ (use-package diminish)
#+end_src
* GCMH
@@ -207,7 +209,6 @@ This package helps improve the garbage collection settings to match modern compu
#+begin_src emacs-lisp
(use-package gcmh
- :ensure t
:diminish gcmh-mode
:init
(gcmh-mode))
@@ -216,8 +217,7 @@ This package helps improve the garbage collection settings to match modern compu
* Hydra
#+begin_src emacs-lisp
- (use-package hydra
- :ensure t)
+ (use-package hydra)
#+end_src
* Delete Trailing Whitespace
@@ -231,8 +231,7 @@ It bugs me to have whitespace left over.
* Consult
#+begin_src emacs-lisp
- (use-package consult
- :ensure t)
+ (use-package consult)
#+end_src
* Diff-hl
@@ -241,7 +240,6 @@ Highlight diffs in the fringe.
#+begin_src emacs-lisp
(use-package diff-hl
- :ensure t
:init
(global-diff-hl-mode))
#+end_src
@@ -250,24 +248,31 @@ Highlight diffs in the fringe.
#+begin_src emacs-lisp
(use-package vertico
- :ensure t)
+ :init (vertico-mode)
+ :bind (:map vertico-map
+ ("<return>" . vertico-directory-enter)
+ ("<backspace>" . vertico-directory-delete-char)
+ ("M-<backspace>" . vertico-directory-delete-word)))
(use-package vertico-prescient
- :ensure t)
+ :init (vertico-prescient-mode))
+
+ (use-package vertico-posframe
+ :init (vertico-posframe-mode)
+ :config
+ (setq vertico-posframe-poshandler 'posframe-poshandler-frame-bottom-center))
#+end_src
* Marginalia
#+begin_src emacs-lisp
- (use-package marginalia
- :ensure t)
+ (use-package marginalia)
#+end_src
* Ace Window
#+begin_src emacs-lisp
(use-package ace-window
- :ensure t
:bind (("M-o" . ace-window)
("C-x o")))
#+end_src
@@ -566,12 +571,6 @@ Highlight diffs in the fringe.
;; (with-eval-after-load 'tramp (require 'oni-tramp nil t))
;; (with-eval-after-load 'web-mode (require 'oni-web nil t))
- (with-eval-after-load 'yasnippet
- (require 'oni-yasnippet)
- (when (and (package-installed-p 'oni-yasnippet)
- (not yas-global-mode))
- (yas-global-mode)))
-
(eval-when-compile
(require 'calendar))
@@ -816,6 +815,12 @@ Highlight diffs in the fringe.
(setq switch-to-buffer-obey-display-actions t)
#+end_src
+* Rainbow Delimiters
+
+#+begin_src emacs-lisp
+ (use-package rainbow-delimiters)
+#+end_src
+
* Custom
Change the file where =customize= stores its settings.