dev: merge from master

This commit is contained in:
Matt Nish-Lapidus 2024-08-20 10:34:32 -04:00
commit f09f343a6f
23 changed files with 115 additions and 108 deletions

View file

@ -284,7 +284,6 @@
:desc "Search project for symbol" "." #'+default/search-project-for-symbol-at-point :desc "Search project for symbol" "." #'+default/search-project-for-symbol-at-point
:desc "Find file in other project" "F" #'doom/find-file-in-other-project :desc "Find file in other project" "F" #'doom/find-file-in-other-project
:desc "Search project" "s" #'+default/search-project :desc "Search project" "s" #'+default/search-project
:desc "List project todos" "t" #'magit-todos-list
:desc "Open project scratch buffer" "x" #'doom/open-project-scratch-buffer :desc "Open project scratch buffer" "x" #'doom/open-project-scratch-buffer
:desc "Switch to project scratch buffer" "X" #'doom/switch-to-project-scratch-buffer :desc "Switch to project scratch buffer" "X" #'doom/switch-to-project-scratch-buffer
(:when (and (modulep! :tools taskrunner) (:when (and (modulep! :tools taskrunner)

View file

@ -747,7 +747,6 @@
:desc "Find recent project files" "r" #'projectile-recentf :desc "Find recent project files" "r" #'projectile-recentf
:desc "Run project" "R" #'projectile-run-project :desc "Run project" "R" #'projectile-run-project
:desc "Save project files" "s" #'projectile-save-project-buffers :desc "Save project files" "s" #'projectile-save-project-buffers
:desc "List project todos" "t" #'magit-todos-list
:desc "Test project" "T" #'projectile-test-project :desc "Test project" "T" #'projectile-test-project
:desc "Pop up scratch buffer" "x" #'doom/open-project-scratch-buffer :desc "Pop up scratch buffer" "x" #'doom/open-project-scratch-buffer
:desc "Switch to scratch buffer" "X" #'doom/switch-to-project-scratch-buffer :desc "Switch to scratch buffer" "X" #'doom/switch-to-project-scratch-buffer
@ -833,6 +832,7 @@
(:prefix-map ("t" . "toggle") (:prefix-map ("t" . "toggle")
:desc "Big mode" "b" #'doom-big-font-mode :desc "Big mode" "b" #'doom-big-font-mode
:desc "Fill Column Indicator" "c" #'global-display-fill-column-indicator-mode :desc "Fill Column Indicator" "c" #'global-display-fill-column-indicator-mode
:desc "Diff Highlights (Git Gutter)" "d" #'diff-hl-mode
:desc "Flymake" "f" #'flymake-mode :desc "Flymake" "f" #'flymake-mode
(:when (and (modulep! :checkers syntax) (:when (and (modulep! :checkers syntax)
(not (modulep! :checkers syntax +flymake))) (not (modulep! :checkers syntax +flymake)))

View file

@ -89,7 +89,8 @@ This is controlled by `+format-on-save-disabled-modes'."
(setf (alist-get formatter apheleia-formatters) (setf (alist-get formatter apheleia-formatters)
(append (delete '(apheleia-formatters-js-indent "--use-tabs" "--tab-width") (append (delete '(apheleia-formatters-js-indent "--use-tabs" "--tab-width")
(alist-get formatter apheleia-formatters)) (alist-get formatter apheleia-formatters))
'(unless (or (cl-loop for file '((when apheleia-formatters-respect-indent-level
(unless (or (cl-loop for file
in '(".prettierrc" in '(".prettierrc"
".prettierrc.json" ".prettierrc.json"
".prettierrc.yml" ".prettierrc.yml"
@ -102,4 +103,4 @@ This is controlled by `+format-on-save-disabled-modes'."
if (locate-dominating-file default-directory file) if (locate-dominating-file default-directory file)
return t) return t)
(assq 'prettier (+javascript-npm-conf))) (assq 'prettier (+javascript-npm-conf)))
(apheleia-formatters-indent "--use-tabs" "--tab-width")))))) (apheleia-formatters-indent "--use-tabs" "--tab-width"))))))))

View file

@ -203,6 +203,14 @@ Fixes #3939: unsortable dired entries on Windows."
(car (last (cdr result)))))) (car (last (cdr result))))))
result))) result)))
;; HACK: Suppress mode hooks when previewing files, as they may contain
;; expensive or disruptive functionality that isn't needed just for
;; previewing them.
;; REVIEW: Upstream this later?
(defadvice! +dired--suppress-hooks-in-previews-a (fn &rest args)
:around #'dirvish--find-file-temporarily
(delay-mode-hooks (apply fn args)))
;; HACK: Dirvish will complain that pdf-tools is required to preview PDFs, ;; HACK: Dirvish will complain that pdf-tools is required to preview PDFs,
;; even if the package is installed, so I advise it to try autoloading it ;; even if the package is installed, so I advise it to try autoloading it
;; before complaining, otherwise complain if epdfinfo hasn't been built yet. ;; before complaining, otherwise complain if epdfinfo hasn't been built yet.

View file

@ -2,8 +2,8 @@
;;; emacs/undo/packages.el ;;; emacs/undo/packages.el
(if (modulep! +tree) (if (modulep! +tree)
(package! undo-tree :pin "5e9f4c92348b3cfd6f140c1730294017dca4bc05") (package! undo-tree :pin "d8f72bbe7d3c3a2808986febd3bb1a46d4da7f51")
(package! undo-fu :pin "ea902716f39c725db1b90dbb285b44404b3bd6df") (package! undo-fu :pin "dbb3e4b699dd488497ef9b32a04b8e928a6bc8ef")
(package! undo-fu-session :pin "75d78310c86901f01b35d47f3ac1a5c8368abba4") (package! undo-fu-session :pin "beb0e285d074145eaf481a959c903b77c19ae91e")
(when (> emacs-major-version 27) ; unsupported in 27 (when (> emacs-major-version 27) ; unsupported in 27
(package! vundo :pin "a18d63a9a15d363c11e2405934e709723e472d86"))) (package! vundo :pin "5374125dc0aaf1769bb0965344befb90f809ccfc")))

View file

@ -6,9 +6,9 @@
(package! smerge-mode :built-in t) (package! smerge-mode :built-in t)
(package! browse-at-remote :pin "76aa27dfd469fcae75ed7031bb73830831aaccbf") (package! browse-at-remote :pin "76aa27dfd469fcae75ed7031bb73830831aaccbf")
(package! git-commit :pin "e77782272082977d56635308b89cf686abd87ef5") (package! git-commit :pin "55656a31cc4fe6c8996c621f4cf14aa4a1bfe47d")
(package! git-timemachine (package! git-timemachine
;; The original lives on codeberg.org; which has uptime issues. ;; The original lives on codeberg.org; which has uptime issues.
:recipe (:host github :repo "emacsmirror/git-timemachine") :recipe (:host github :repo "emacsmirror/git-timemachine")
:pin "3780835fcd67c3703ffa768206121851e6895ece") :pin "3780835fcd67c3703ffa768206121851e6895ece")
(package! git-modes :pin "d96fa7a3c7d754812675b37247c6a77e459eec53") (package! git-modes :pin "f99010bbeb8b6d8a0819fac0195a2ef0159d08f0")

View file

@ -10,8 +10,8 @@
(when (modulep! :completion vertico) (when (modulep! :completion vertico)
(package! citar :pin "07d2a63c99fe35cbd468f8e6a322de05f1a29469") (package! citar :pin "07d2a63c99fe35cbd468f8e6a322de05f1a29469")
(package! citar-embark :pin "07d2a63c99fe35cbd468f8e6a322de05f1a29469") (package! citar-embark :pin "07d2a63c99fe35cbd468f8e6a322de05f1a29469")
(when (modulep! :lang org +roam2) (when (modulep! :lang org +roam)
(package! citar-org-roam :pin "82d47b5df1926627f56a09055c69b49b31cbbb9f"))) (package! citar-org-roam :pin "82d47b5df1926627f56a09055c69b49b31cbbb9f")))
(package! parsebib :pin "ace9df707108b17759c004c7387655277122d4c1") (package! parsebib :pin "ace9df707108b17759c004c7387655277122d4c1")
(package! citeproc :pin "cfa30b6c95c7465a05da98eccf273608880b22d7") (package! citeproc :pin "54184baaff555b5c7993d566d75dd04ed485b5c0")

View file

@ -1,4 +1,4 @@
;; -*- no-byte-compile: t; -*- ;; -*- no-byte-compile: t; -*-
;;; tools/collab/packages.el ;;; tools/collab/packages.el
(package! crdt :pin "9bf99e2ce35d23c3d60ad245b77ab3b5313184d4") (package! crdt :pin "7f91efcc727e8da2485cdaf9223d7ca7177aa2a9")

View file

@ -6,5 +6,5 @@
(package! realgud-trepan-ni :pin "0ec088ea343835e24ae73da09bea96bfb02a3130"))) (package! realgud-trepan-ni :pin "0ec088ea343835e24ae73da09bea96bfb02a3130")))
(when (modulep! +lsp) (when (modulep! +lsp)
(package! dap-mode :pin "b407773ebca56e3bd8e6a4643854e91cbde0c35e") (package! dap-mode :pin "496dd3a60f71a396df7e9a5ff6c500127d00ec03")
(package! posframe :pin "f4e9e509ba96ceb3c2b2b054957291607fb52651")) (package! posframe :pin "493b17f74ad41104d0c4d648e8c96dc495279ac8"))

View file

@ -1,4 +1,4 @@
;; -*- no-byte-compile: t; -*- ;; -*- no-byte-compile: t; -*-
;;; tools/direnv/packages.el ;;; tools/direnv/packages.el
(package! envrc :pin "2316e004c1574234fe4d991bd75a254cdeaa83ae") (package! envrc :pin "532ecdab48d073963ba5b581c06f3c0b83db05a6")

View file

@ -1,7 +1,7 @@
;; -*- no-byte-compile: t; -*- ;; -*- no-byte-compile: t; -*-
;;; tools/docker/packages.el ;;; tools/docker/packages.el
(package! docker :pin "d5255a65b7240d0038cc417f301b43df05a27922") (package! docker :pin "f3adbf49e1140d13c934f16e19754c42a97dc91f")
;; tramp-container (included with Emacs 29+) replaces docker-tramp ;; tramp-container (included with Emacs 29+) replaces docker-tramp
(when (< emacs-major-version 29) (when (< emacs-major-version 29)
(package! docker-tramp :pin "19d0771db4e6b89e19c00af5806438e315779c15")) (package! docker-tramp :pin "19d0771db4e6b89e19c00af5806438e315779c15"))

View file

@ -3,4 +3,4 @@
(package! editorconfig (package! editorconfig
:recipe (:nonrecursive t) :recipe (:nonrecursive t)
:pin "1651294334f3987d749eeb287f11d256cf2ba5b1") :pin "648f0cf9aeb72db77b252832a58367332b7bc055")

View file

@ -8,7 +8,7 @@
(package! helm)) (package! helm))
;; ;;
(package! dumb-jump :pin "3c2ab8dfff3a10d3c5f2efd69cfbc81fb5dbbd39") (package! dumb-jump :pin "cd65a743370ac7b1a12e9ef0a7371b285a2597fb")
(when (modulep! :completion ivy) (when (modulep! :completion ivy)
(package! ivy-xref :pin "a82e8e117d2dd62c28b6a3e3d6e4cfb11c0bda38")) (package! ivy-xref :pin "a82e8e117d2dd62c28b6a3e3d6e4cfb11c0bda38"))
(when (modulep! :completion helm) (when (modulep! :completion helm)

View file

@ -3,14 +3,14 @@
(if (modulep! +eglot) (if (modulep! +eglot)
(progn (progn
(package! eglot :pin "8008255edd74d8bda75e01ed747c2460e28404ac") (package! eglot :pin "3a5240d8fd3e936aaa452285db087988a438dc81")
(when (modulep! :completion vertico) (when (modulep! :completion vertico)
(package! consult-eglot :pin "64262e72452f8fe6dd49d31bcdd4bd577b7d682d")) (package! consult-eglot :pin "64262e72452f8fe6dd49d31bcdd4bd577b7d682d"))
(when (and (modulep! :checkers syntax) (when (and (modulep! :checkers syntax)
(not (modulep! :checkers syntax +flymake))) (not (modulep! :checkers syntax +flymake)))
(package! flycheck-eglot :pin "09e37f4c726d9b565b040ba9e89215158d3bd6b6"))) (package! flycheck-eglot :pin "09e37f4c726d9b565b040ba9e89215158d3bd6b6")))
(package! lsp-mode :pin "52987755175042b9569e32d72ae29eba119020d6") (package! lsp-mode :pin "12befaabe4a1bf8a548bc820faa192be8ee89533")
(package! lsp-ui :pin "00f1fecdfb41c30428734cf27e492f26f46627fb") (package! lsp-ui :pin "072bb29152038518c2478813b82c8d04d07df84c")
(when (modulep! :completion ivy) (when (modulep! :completion ivy)
(package! lsp-ivy :pin "9ecf4dd9b1207109802bd1882aa621eb1c385106")) (package! lsp-ivy :pin "9ecf4dd9b1207109802bd1882aa621eb1c385106"))
(when (modulep! :completion helm) (when (modulep! :completion helm)

View file

@ -183,13 +183,6 @@ Only has an effect in GUI Emacs.")
'("c r" "Review pull request" +magit/start-code-review)))) '("c r" "Review pull request" +magit/start-code-review))))
(use-package! magit-todos
:after magit
:config
(setq magit-todos-keyword-suffix "\\(?:([^)]+)\\)?:?") ; make colon optional
(define-key magit-todos-section-map "j" nil))
(use-package! evil-collection-magit (use-package! evil-collection-magit
:when (modulep! :editor evil +everywhere) :when (modulep! :editor evil +everywhere)
:defer t :defer t

View file

@ -1,12 +1,11 @@
;; -*- no-byte-compile: t; -*- ;; -*- no-byte-compile: t; -*-
;;; tools/magit/packages.el ;;; tools/magit/packages.el
(when (package! magit :pin "e77782272082977d56635308b89cf686abd87ef5") (package! magit :pin "cf94190410ef163fd102cdbcb67f28599d31eabc")
(when (modulep! +forge) (when (modulep! +forge)
(package! forge :pin "21d410c8102422f32db14ddac4eae9e28c2b5c5a") (package! forge :pin "a56eb3cbb27c61387d35cbff6b036a2c1bc1559d")
(package! code-review (package! code-review
:recipe (:host github :recipe (:host github
:repo "doomelpa/code-review" :repo "doomelpa/code-review"
:files ("graphql" "code-review*.el")) :files ("graphql" "code-review*.el"))
:pin "e4c34fa284da25d8e0bafbae4300f1db5bdcda44")) :pin "e4c34fa284da25d8e0bafbae4300f1db5bdcda44"))
(package! magit-todos :pin "501c8db90ab59f8b619618b9d10db2a32a113727"))

View file

@ -2,4 +2,4 @@
;;; tools/pdf/packages.el ;;; tools/pdf/packages.el
(package! pdf-tools :pin "30b50544e55b8dbf683c2d932d5c33ac73323a16") (package! pdf-tools :pin "30b50544e55b8dbf683c2d932d5c33ac73323a16")
(package! saveplace-pdf-view :pin "ee95460cd934080338f03a16f95b549577425216") (package! saveplace-pdf-view :pin "70e9ec40565021f4b5d51e4523f4c716183a8eef")

View file

@ -1,6 +1,6 @@
;; -*- no-byte-compile: t; -*- ;; -*- no-byte-compile: t; -*-
;;; tools/terraform/packages.el ;;; tools/terraform/packages.el
(package! terraform-mode :pin "a645c32a8f0f0d04034262ae5fea330d5c7a33c6") (package! terraform-mode :pin "abfc10f5e313c4bb99de136a14636e9bc6df74f6")
(when (modulep! :completion company) (when (modulep! :completion company)
(package! company-terraform :pin "8d5a16d1bbeeb18ca49a8fd57b5d8cd30c8b8dc7")) (package! company-terraform :pin "8d5a16d1bbeeb18ca49a8fd57b5d8cd30c8b8dc7"))

View file

@ -2,7 +2,7 @@
;;; tools/tree-sitter/packages.el ;;; tools/tree-sitter/packages.el
(package! tree-sitter :recipe (:branch "master") :pin "02fe7b86d92b1aab954045146469b7893f0ab371") (package! tree-sitter :recipe (:branch "master") :pin "02fe7b86d92b1aab954045146469b7893f0ab371")
(package! tree-sitter-langs :pin "b2739d07fadf45520a25862342a1790cd905cff9") (package! tree-sitter-langs :pin "1c3d95d018c6ab09dbe0b31530bfb1865fac2e5f")
(package! tree-sitter-indent :pin "4ef246db3e4ff99f672fe5e4b416c890f885c09e") (package! tree-sitter-indent :pin "4ef246db3e4ff99f672fe5e4b416c890f885c09e")
(when (modulep! :editor evil +everywhere) (when (modulep! :editor evil +everywhere)

View file

@ -227,12 +227,12 @@ If you want to "start from scratch" and get control over all ligatures that
happen in all modes, you can use happen in all modes, you can use
#+begin_src elisp #+begin_src elisp
;; Set all your custom ligatures for all prog-modes here ;; Set all your custom ligatures for all prog-modes here.
;; This section is *out of* the after! block ;; This section is *out of* the after! block.
;; Example: only get ligatures for "==" and "===" in programming modes ;; Example: only get ligatures for "==" and "===" in programming modes by
;; by default, and get only "www" in all buffers by default. ;; default, and get only "www" in all buffers by default.
(setq +ligatures-prog-mode-list '("==" "===") (set-font-ligatures! 'prog-mode :append "==" "===")
+ligatures-all-modes-list '("www")) (set-font-ligatures! 't :append "www")
;; Set any of those variables to nil to wipe all defaults. ;; Set any of those variables to nil to wipe all defaults.
;; Set all your additional custom ligatures for other major modes here. ;; Set all your additional custom ligatures for other major modes here.

View file

@ -60,22 +60,24 @@ For example, the rule for emacs-lisp-mode is very simple:
This will ligate \"->\" into the arrow of choice according to your font. This will ligate \"->\" into the arrow of choice according to your font.
Font ligatures can be unset for emacs-lisp-mode with: All font ligatures for emacs-lisp-mode can be unset with:
(set-font-ligatures! \\='emacs-lisp-mode nil) (set-font-ligatures! \\='emacs-lisp-mode nil)
Note that this will keep all ligatures in `+ligatures-prog-mode-list' active, as However, ligatures for any parent modes (like `prog-mode') will still be in
`emacs-lisp-mode' is derived from `prog-mode'." effect, as `emacs-lisp-mode' is derived from `prog-mode'."
(declare (indent defun)) (declare (indent defun))
;; NOTE: Doom enforces `ligature-composition-table' to have a single mode per key in the alist.
;; This is less efficient than what ligature.el can do (i.e. use a list of modes, or `t' as a key),
;; but holding this invariant allows resetting with `(set-font-ligatures! 'mode nil)` to work reliably.
(if (or (null ligatures) (equal ligatures '(nil)))
(dolist (mode (ensure-list modes))
(delq! mode ligature-composition-table 'assq))
(after! ligature (after! ligature
(dolist (mode (ensure-list modes)) (if (or (null ligatures) (equal ligatures '(nil)))
(setq ligature-ignored-major-modes (delq mode ligature-ignored-major-modes)) (dolist (table ligature-composition-table)
(ligature-set-ligatures mode ligatures))))) (let ((modes (ensure-list modes))
(tmodes (car table)))
(cond ((and (listp tmodes) (cl-intersection modes tmodes))
(let ((tmodes (cl-nset-difference tmodes modes)))
(setq ligature-composition-table
(if tmodes
(cons tmodes (cdr table))
(delete table ligature-composition-table)))))
((memq tmodes modes)
(setq ligature-composition-table (delete table ligature-composition-table))))))
(ligature-set-ligatures modes ligatures))))

View file

@ -44,11 +44,8 @@ This should not contain any symbols from the Unicode Private Area! There is no
universal way of getting the correct symbol as that area varies from font to universal way of getting the correct symbol as that area varies from font to
font.") font.")
(defvar +ligatures-extra-alist '((t)) (defvar +ligatures-alist
"A map of major modes to symbol lists (for `prettify-symbols-alist').") '((prog-mode "|||>" "<|||" "<==>" "<!--" "####" "~~>" "***" "||=" "||>"
(defvar +ligatures-prog-mode-list
'("|||>" "<|||" "<==>" "<!--" "####" "~~>" "***" "||=" "||>"
":::" "::=" "=:=" "===" "==>" "=!=" "=>>" "=<<" "=/=" "!==" ":::" "::=" "=:=" "===" "==>" "=!=" "=>>" "=<<" "=/=" "!=="
"!!." ">=>" ">>=" ">>>" ">>-" ">->" "->>" "-->" "---" "-<<" "!!." ">=>" ">>=" ">>>" ">>-" ">->" "->>" "-->" "---" "-<<"
"<~~" "<~>" "<*>" "<||" "<|>" "<$>" "<==" "<=>" "<=<" "<->" "<~~" "<~>" "<*>" "<||" "<|>" "<$>" "<==" "<=>" "<=<" "<->"
@ -61,11 +58,19 @@ font.")
"##" "#(" "#?" "#_" "%%" ".=" ".-" ".." ".?" "+>" "++" "?:" "##" "#(" "#?" "#_" "%%" ".=" ".-" ".." ".?" "+>" "++" "?:"
"?=" "?." "??" ";;" "/*" "/=" "/>" "//" "__" "~~" "(*" "*)" "?=" "?." "??" ";;" "/*" "/=" "/>" "//" "__" "~~" "(*" "*)"
"\\\\" "://") "\\\\" "://")
"A list of ligatures to enable in all `prog-mode' buffers.") (t))
"A alist of ligatures to enable in specific modes.")
(defvar +ligatures-all-modes-list (defvar +ligatures-prog-mode-list nil
'() "A list of ligatures to enable in all `prog-mode' buffers.")
(make-obsolete-variable '+ligatures-prog-mode-list "Use `+ligatures-alist' instead" "v3.0.0")
(defvar +ligatures-all-modes-list nil
"A list of ligatures to enable in all buffers.") "A list of ligatures to enable in all buffers.")
(make-obsolete-variable '+ligatures-all-modes-list "Use `+ligatures-alist' instead" "v3.0.0")
(defvar +ligatures-extra-alist '((t))
"A map of major modes to symbol lists (for `prettify-symbols-alist').")
(defvar +ligatures-in-modes (defvar +ligatures-in-modes
'(not special-mode comint-mode eshell-mode term-mode vterm-mode Info-mode '(not special-mode comint-mode eshell-mode term-mode vterm-mode Info-mode
@ -169,14 +174,14 @@ and cannot run in."
(featurep 'harfbuzz)) (featurep 'harfbuzz))
(featurep 'composite)) ; Emacs loads `composite' at startup (featurep 'composite)) ; Emacs loads `composite' at startup
(use-package! ligature (after! ligature
:config ;; DEPRECATED: For backwards compatibility. Remove later.
;; Enable all `+ligatures-prog-mode-list' ligatures in programming modes (with-no-warnings
(ligature-set-ligatures 'prog-mode +ligatures-prog-mode-list) (when +ligatures-prog-mode-list
(ligature-set-ligatures 't +ligatures-all-modes-list)) (setf (alist-get 'prog-mode +ligatures-alist) +ligatures-prog-mode-list))
(when +ligatures-all-modes-list
(setf (alist-get t +ligatures-alist) +ligatures-all-modes-list)))
(dolist (lig +ligatures-alist)
(ligature-set-ligatures (car lig) (cdr lig))))
(add-hook! 'doom-init-ui-hook :append (add-hook 'doom-init-ui-hook #'global-ligature-mode 'append)))
(defun +ligature-enable-globally-h ()
"Enables ligature checks globally in all buffers.
You can also do it per mode with `ligature-mode'."
(global-ligature-mode t)))))

View file

@ -1,5 +1,5 @@
(when (and (or (featurep 'ns) (when (and (or (featurep 'ns)
(string-match-p "HARFBUZZ" system-configuration-features)) (featurep 'harfbuzz))
(featurep 'composite)) (featurep 'composite))
(package! ligature (package! ligature
:pin "6ac1634612dbd42f7eb81ecaf022bd239aabb954")) :pin "6ac1634612dbd42f7eb81ecaf022bd239aabb954"))