From adf815b61bfd850e948e60b743ce48b0ff42d901 Mon Sep 17 00:00:00 2001 From: Case Duckworth Date: Fri, 21 Jan 2022 16:34:55 -0600 Subject: Two out of three ain't bad --- init.el | 31 +++++++++++++++++++++++++++---- 1 file changed, 27 insertions(+), 4 deletions(-) (limited to 'init.el') diff --git a/init.el b/init.el index b930513..6940a12 100644 --- a/init.el +++ b/init.el @@ -143,6 +143,10 @@ '("firefox" "chromium" "chrome")) + browse-url-chrome-program (seq-some #'executable-find + '("chromium" + "chrome" + "google-chrome-stable")) browse-url-generic-args (seq-some (lambda (e) (when (equal (executable-find (car e)) browse-url-generic-program) @@ -488,7 +492,7 @@ org-tags-column (- (- fill-column (length org-ellipsis))) org-todo-keywords '((sequence "TODO(t)" "WAIT(w@/!)" "|" "DONE(d!)") - (sequence "|" "CANCELED(k!)") + (sequence "|" "CANCELED(k@/!)") (sequence "MEETING(m)"))) (:bind "RET" #'+org-return-dwim "" #'+org-table-copy-down @@ -595,7 +599,7 @@ (setup scratch (:require +scratch) - (:option initial-major-mode #'lisp-interaction-mode + (:option initial-major-mode #'emacs-lisp-mode initial-scratch-message ";; ABANDON ALL HOPE YE WHO ENTER HERE\n\n") (add-hook 'kill-buffer-query-functions #'+scratch-immortal)) @@ -1089,6 +1093,8 @@ See also `crux-reopen-as-root-mode'." "&" #'+elfeed-show-browse-generic "RET" #'shr-browse-url) (:hook #'reading-mode) + (:option +elfeed--update-repeat (* 60 60) ; 1 hour + +elfeed--update-first-time 60) (+elfeed-update-async-mode +1))) (setup (:straight elfeed-org) @@ -1350,6 +1356,14 @@ See also `crux-reopen-as-root-mode'." #'hl-line-mode #'lin-mode)) +(setup (:straight md4rd) + ;; `md4rd' is ... a bit janky, tbh. But I'm including this here so I have it. + ;; TODO: enable opening Reddit links in md4rd + (:also-load _md4rd) + (defalias 'reddit 'md4rd "Browse Reddit.") + (with-eval-after-load 'md4rd + (run-with-timer 0 (* 60 59) 'md4rd-refresh-login))) + (setup (:straight minions) (minions-mode +1)) @@ -1364,11 +1378,12 @@ See also `crux-reopen-as-root-mode'." :host gitlab :repo "protesilaos/modus-themes")) (require 'modus-themes (.etc "straight/build/modus-themes/modus-themes")) + (:also-load dawn) (:option modus-themes-mixed-fonts t modus-themes-bold-constructs t modus-themes-italic-constructs t modus-themes-headings '((t . (background)))) - (+sunrise-sunset 'modus-themes-load-operandi 'modus-themes-load-vivendi)) + (dawn-schedule #'modus-themes-load-operandi #'modus-themes-load-vivendi)) (setup (:straight mwim) (:require +mwim) @@ -1379,7 +1394,7 @@ See also `crux-reopen-as-root-mode'." "C-e" #'+mwim-end-maybe)) (setup (:straight orderless) - (:also-load +orderless) + (:require +orderless) (:option completion-styles '(substring orderless basic) completion-category-defaults nil completion-category-overrides @@ -1447,6 +1462,8 @@ See also `crux-reopen-as-root-mode'." ;; Ensure we can build `pdf-tools' (or (executable-find "gcc") (executable-find "g++"))) + (setf (alist-get "\\.pdf\\'" auto-mode-alist nil nil #'equal) + #'pdf-view-modei) (pdf-tools-install t)) (setup (:straight (shell-command+ @@ -1590,6 +1607,11 @@ See also `crux-reopen-as-root-mode'." undo-fu-session-compression (executable-find "gzip")) (global-undo-fu-session-mode +1)) +(setup (:straight valign) + (:option valign-fancy-bar t) + (:hook-into org-mode + markdown-mode)) + (setup (:straight (vertico :host github :repo "minad/vertico" @@ -1624,6 +1646,7 @@ See also `crux-reopen-as-root-mode'." ;; This is applied /after/ the above, so default is at the end of ;; this alist. vertico-multiform-categories '((file buffer grid) + (bookmark) (t flat))) (dolist (buf-cmd '(consult-find consult-yank-pop -- cgit 1.4.1-21-gabe81