dev: merge branch 'master' of github.com:doomemacs

This commit is contained in:
Matt Nish-Lapidus 2024-07-19 11:45:16 -04:00
commit a924e32652
12 changed files with 42 additions and 29 deletions

View file

@ -23,14 +23,14 @@
(jobs ("-j" "--jobs" num) "How many CPUs to use for native compilation") (jobs ("-j" "--jobs" num) "How many CPUs to use for native compilation")
(nobuild? ("-B") "Don't rebuild packages when hostname or Emacs version has changed") (nobuild? ("-B") "Don't rebuild packages when hostname or Emacs version has changed")
&context context) &context context)
"Updates Doom and packages. "Updates Doom's core, module libraries, and installed packages.
This requires that ~/.emacs.d is a git repo, and is the equivalent of the A convenience command for updating Doom's core and pinned modules/module
following shell commands: libraries. It is the equivalent of the following shell commands:
cd ~/.emacs.d $ cd ~/.emacs.d
git pull --rebase $ git pull --rebase
doom sync -u" $ doom sync -u"
(let* ((force? (doom-cli-context-suppress-prompts-p context)) (let* ((force? (doom-cli-context-suppress-prompts-p context))
(sync-cmd (append '("sync" "-u") (sync-cmd (append '("sync" "-u")
(if nobuild? '("-B")) (if nobuild? '("-B"))

View file

@ -606,8 +606,8 @@ Only use this macro in a module's (or your private) packages.el file."
(defmacro unpin! (&rest targets) (defmacro unpin! (&rest targets)
"Unpin packages in TARGETS. "Unpin packages in TARGETS.
This unpins packages, so that 'doom upgrade' downloads their latest version. It This unpins packages, so that `doom upgrade' or `doom sync -u' will update them
can be used one of five ways: to the latest commit available. Some examples:
- To disable pinning wholesale: (unpin! t) - To disable pinning wholesale: (unpin! t)
- To unpin individual packages: (unpin! packageA packageB ...) - To unpin individual packages: (unpin! packageA packageB ...)

View file

@ -73,6 +73,9 @@ And jumps to your `doom!' block."
(defun doom/reload () (defun doom/reload ()
"Reloads your private config. "Reloads your private config.
WARNING: This command is experimental! If you haven't configured your config to
be idempotent, then this could cause compounding slowness or errors.
This is experimental! It will try to do as `bin/doom sync' does, but from within This is experimental! It will try to do as `bin/doom sync' does, but from within
this Emacs session. i.e. it reload autoloads files (if necessary), reloads your this Emacs session. i.e. it reload autoloads files (if necessary), reloads your
package list, and lastly, reloads your private config.el. package list, and lastly, reloads your private config.el.

View file

@ -270,9 +270,9 @@
(advice-add #'delete-backward-char :override #'+default--delete-backward-char-a) (advice-add #'delete-backward-char :override #'+default--delete-backward-char-a)
;; HACK Makes `newline-and-indent' continue comments (and more reliably). ;; HACK Makes `newline-and-indent' continue comments (and more reliably).
;; Consults `doom-point-in-comment-functions' to detect a commented region ;; Consults `doom-point-in-comment-p' to detect a commented region and uses
;; and uses that mode's `comment-line-break-function' to continue comments. ;; that mode's `comment-line-break-function' to continue comments. If
;; If neither exists, it will fall back to the normal behavior of ;; neither exists, it will fall back to the normal behavior of
;; `newline-and-indent'. ;; `newline-and-indent'.
;; ;;
;; We use an advice here instead of a remapping because many modes define ;; We use an advice here instead of a remapping because many modes define
@ -281,9 +281,7 @@
;; on a case by case basis. ;; on a case by case basis.
(defadvice! +default--newline-indent-and-continue-comments-a (&rest _) (defadvice! +default--newline-indent-and-continue-comments-a (&rest _)
"A replacement for `newline-and-indent'. "A replacement for `newline-and-indent'.
Continues comments if executed from a commented line."
Continues comments if executed from a commented line. Consults
`doom-point-in-comment-functions' to determine if in a comment."
:before-until #'newline-and-indent :before-until #'newline-and-indent
(interactive "*") (interactive "*")
(when (and +default-want-RET-continue-comments (when (and +default-want-RET-continue-comments

View file

@ -15,6 +15,17 @@
(when (modulep! +lsp) (when (modulep! +lsp)
(add-hook 'beancount-mode-local-vars-hook #'lsp! 'append)) (add-hook 'beancount-mode-local-vars-hook #'lsp! 'append))
;; HACK: The intro message changed in newer versions of Fava, plus, the output
;; could contain ANSI codes, causing the `beancount-fava' command to not
;; open the server in the browser after the server has started.
;; REVIEW: PR this uptsream!
(defadvice! +beancount--open-in-browser-after-starting-fix-a (_process output)
:override #'beancount--fava-filter
(save-match-data
(let ((output (ansi-color-filter-apply output)))
(when-let ((url (string-match "\\(?:Starting\\|Running\\) Fava on \\(http://.+:[0-9]+\\)\n" output)))
(browse-url (match-string 1 output))))))
(map! :map beancount-mode-map (map! :map beancount-mode-map
"TAB" (cmds! (and outline-minor-mode (outline-on-heading-p)) "TAB" (cmds! (and outline-minor-mode (outline-on-heading-p))
#'beancount-outline-cycle #'beancount-outline-cycle

View file

@ -91,11 +91,6 @@
:when (modulep! +lsp) :when (modulep! +lsp)
:when (modulep! :tools lsp +eglot) :when (modulep! :tools lsp +eglot)
:after eglot :after eglot
:preface
;; Prevent auto-install of LanguageServer.jl
(setq eglot-jl-language-server-project
(or (car (last (doom-glob "~/.julia/environments/v*")))
"~/.julia/environments/v1.6"))
:init :init
;; Prevent timeout while installing LanguageServer.jl ;; Prevent timeout while installing LanguageServer.jl
(setq-hook! 'julia-mode-hook eglot-connect-timeout (max eglot-connect-timeout 60)) (setq-hook! 'julia-mode-hook eglot-connect-timeout (max eglot-connect-timeout 60))

View file

@ -23,7 +23,7 @@
(with-temp-file "org-version.el" (with-temp-file "org-version.el"
(let ((version (let ((version
(with-temp-buffer (with-temp-buffer
(insert-file-contents (doom-path "lisp/org.el") nil 0 1024) (insert-file-contents "lisp/org.el" nil 0 1024)
(if (re-search-forward "^;; Version: \\([^\n-]+\\)" nil t) (if (re-search-forward "^;; Version: \\([^\n-]+\\)" nil t)
(match-string-no-properties 1) (match-string-no-properties 1)
"Unknown")))) "Unknown"))))

View file

@ -35,7 +35,7 @@
;; Delete files to trash on macOS, as an extra layer of precaution against ;; Delete files to trash on macOS, as an extra layer of precaution against
;; accidentally deleting wanted files. ;; accidentally deleting wanted files.
(setq delete-by-moving-to-trash t) (setq delete-by-moving-to-trash (not noninteractive))
;; ;;

View file

@ -0,0 +1,6 @@
;;; os/macos/doctor.el -*- lexical-binding: t; -*-
;; See https://lists.gnu.org/archive/html/bug-gnu-emacs/2023-08/msg00560.html
(when (version< emacs-version "29.3")
(warn! "There are bugs in multi-user Keychain integration on Emacs <=29.2")
(explain! "See https://lists.gnu.org/archive/html/bug-gnu-emacs/2023-08/msg00560.html"))

View file

@ -5,9 +5,7 @@
"Please don't leave, there's more demons to toast!" "Please don't leave, there's more demons to toast!"
"Let's beat it -- This is turning into a bloodbath!" "Let's beat it -- This is turning into a bloodbath!"
,(format "I wouldn't leave if I were you. %s is much worse." ,(format "I wouldn't leave if I were you. %s is much worse."
(if (member system-type '(ms-dos-windows-nt cygwin)) (if (featurep :system 'windows) "DOS" "UNIX"))
"DOS"
"UNIX"))
"Don't leave yet -- There's a demon around that corner!" "Don't leave yet -- There's a demon around that corner!"
"Ya know, next time you come in here I'm gonna toast ya." "Ya know, next time you come in here I'm gonna toast ya."
"Go ahead and leave. See if I care." "Go ahead and leave. See if I care."

View file

@ -1,5 +1,5 @@
;; -*- no-byte-compile: t; -*- ;; -*- no-byte-compile: t; -*-
;;; ui/doom/packages.el ;;; ui/doom/packages.el
(package! doom-themes :pin "188ab05eefe2bdc46b4464aadb4a52ff9cb42f7f") (package! doom-themes :pin "2c794a09b023bda09d2f36a7be80684f4e416d88")
(package! solaire-mode :pin "8ccdceeb9298b3c4e35f630914f467bf164f39ad") (package! solaire-mode :pin "c9334666bd208f3322e6118d30eba1b2438e2bb9")

View file

@ -46,9 +46,11 @@ These rules affect buffers displayed with `pop-to-buffer' and `display-buffer'
variants) will not be affected by these rules (as they are unaffected by variants) will not be affected by these rules (as they are unaffected by
`display-buffer-alist', which powers the popup management system). `display-buffer-alist', which powers the popup management system).
PREDICATE can be either a) a regexp string (matched against the buffer's name) PREDICATE accepts anything that the CONDITION argument in `buffer-match-p' takes
or b) a function that takes two arguments (a buffer name and the ACTION argument (if you're on Emacs 29 or newer). On Emacs 28 or older, it can either be a) a
of `display-buffer') and returns a boolean. regexp string (matched against the buffer's name) or b) a function that takes
two arguments (a buffer name and the ACTION argument of `display-buffer') and
returns a boolean.
PLIST can be made up of any of the following properties: PLIST can be made up of any of the following properties: