Commit graph

18931 commits

Author SHA1 Message Date
Levin Du
b121be1c90
fix(cli): doom-packages-ensure: ensure local packages are built
If the package is local, the local-repo has absolute local file path,
and straight-modified-dir will return as it is, which always exists.

Fix it by passing package only to straight-modified-dir.
2024-05-21 17:17:16 +02:00
Levin Du
5e9e569649
fix: doom-initialize-core-packages: extract plist from alist
The doom-package-list is a list of (module :key value ...). To get the
plist, apply cdr first.
2024-05-21 17:17:16 +02:00
Henrik Lissner
2305f503f9
revert: org
emacs-straight/org-mode@e9c288dfac -> emacs-straight/org-mode@5bdfc02c6f

org-mode was bumped in 5f5a163, but this introduced substantial
slowdowns in buffers where src and latex blocks were natively
highlighted. This reverts to the latest known commit that doesn't
present this slowness (which is still newer than the commit used in
5f5a163).

Amend: 5f5a163c4920
2024-05-21 17:17:16 +02:00
Henrik Lissner
7ed7b38999
fix(spell): spell-fu: remove unneeded advice
These issues were addressed upstream.

Ref: emacsmirror/spell-fu@50be652a6e
Ref: emacsmirror/spell-fu@00af362af3
2024-05-21 17:17:16 +02:00
Henrik Lissner
ee03e83847
fix: doom-run-hook-on: check context & chain hooks unconditionally
Consult the doom-context to determine if a transient hook should fire,
rather than after-init-time (less reliable; there may be times we want
them to fire post-init).

Also ensures that they're chained to find-file hooks whether or not this
is a daemon session (since they could concievably be triggered before
the daemon finishes initializing, but after Doom initializes).
2024-05-21 17:17:15 +02:00
Henrik Lissner
ada837ee05
nit: reformat+revise comments
Includes minor refactors to appease the byte-compiler or use more
succinct (but equivalent) syntax.
2024-05-21 17:17:15 +02:00
Henrik Lissner
e89b43ba55
refactor: menu-bar (re)initialization on MacOS
Before this, it was non-trivial to *truly* disable the menu-bar in GUI
frames on MacOS, unless you knew about the
doom-restore-menu-bar-in-gui-frames-h hook and removed it. With this
change, the hook will bow out if the user has tampered with/called
menu-bar-mode at all.
2024-05-21 17:17:15 +02:00
Henrik Lissner
76d9a5b71e
fix: doom-init-fonts-h: don't run more than needed
The face and theme-face manipulation only needs to happen once per
frame, and the `set-fontset-font` calls only need to happen once per
session (or whenever the user calls `M-x doom/reload-fonts`). This
change ensures this and saves Emacs some work when initializing new
frames, as well as resolves `set-fontset-font` related segfaults in some
edge cases (#7803).

Fix: #7803
2024-05-21 17:17:15 +02:00
Henrik Lissner
9872546d21
tweak(helm): helm-always-two-windows = t
Don't comandeer the entire frame for helm commands.
2024-05-21 17:17:15 +02:00
Henrik Lissner
f8459b36de
fix(helm): helm-descbinds-disable-which-key = nil
Otherwise, helm-descbind throws errors if which-key is enabled. Setting
prefix-help-command seems to resolve the incompatibility (more testing
is needed).

Ref: emacs-helm/helm-descbinds@ca03f02da4
Ref: emacs-helm/helm-descbinds@14d1929d54
Amend: 52599ab53647
2024-05-21 17:17:15 +02:00
Henrik Lissner
377dffba38
fix(eval): warnings after eval error
This addresses the warning emitted when evaluating elisp in org-mode:

  Warning (org-element): ‘org-element-at-point’ cannot be used in
  non-Org buffer #<buffer debug.org> (emacs-lisp-mode)

Close: #7753
Fix: #7752
Co-authored-by: pysnow530 <pysnow530@users.noreply.github.com>
2024-05-21 17:17:15 +02:00
StrawberryTea
a629fb9e98
tweak(corfu): update dabbrev-ignore-buffer-modes
The Corfu documentation has been updated to suggest more modes to ignore
with `dabbrev-ignore-buffer-modes`. This commit updates the list of
modes to ignore in `cape-dabbrev` to match the documentation.
2024-05-21 17:17:14 +02:00
Henrik Lissner
fdf2da903c
fix(syntax): flycheck popups clearing active region
Moving the cursor over a flycheck-highlighted error will display the
error message in a popup. Displaying that popup could clear the active
selection (#7242), which is disruptive. This only affected non-Evil
users and users not using the module's +childframe flag, but should no
longer affect anyone after this commit.

Fix: #7242
Ref: flycheck/flycheck-popup-tip#14
2024-05-21 17:17:14 +02:00
Henrik Lissner
bf860138f2
bump: :ui doom
doomemacs/themes@37d2182f50 -> doomemacs/themes@3b2422b208
hlissner/emacs-solaire-mode@8af65fbdc5 -> hlissner/emacs-solaire-mode@8ccdceeb92
2024-05-21 17:17:14 +02:00
Henrik Lissner
51dd268dc6
bump: :editor snippets
doomemacs/snippets@07b3bdaf60 -> doomemacs/snippets@c1384cc797
joaotavora/yasnippet@33587a8551 -> joaotavora/yasnippet@eb5ba2664c

- Recently, yasnippet start complaining about snippets with the same
  name (particularly y-or-n-p and x-file). I've removed/renamed the
  offending snippets in doomemacs/snippets.

Ref: doomemacs/snippets@41417b4398
Ref: doomemacs/snippets@d0a96a37d4
2024-05-21 17:17:14 +02:00
Henrik Lissner
5eb232de25
bump: :app everywhere
tecosaur/emacs-everywhere@fbeff19825 -> tecosaur/emacs-everywhere@bc91164151

Ref: tecosaur/emacs-everywhere#75
Revert: b439300e6a0c
2024-05-21 17:17:14 +02:00
Prashant Vithani
19f5dab48c
bump: :lang scala
hvesalai/emacs-sbt-mode@bcf8d60400 -> hvesalai/emacs-sbt-mode@cc68728a6e
2024-05-21 17:17:14 +02:00
Henrik Lissner
88d4f49356
fix(workspaces): dual *Warnings* windows at startup
At some point, either Emacs, persp-mode, or I fixed what caused #319,
which swallows the *Warnings* popup when the new main workspace is
created. Until I can determine what fixed it (so I can determine whether
the whole hack should go), I'll simply add this guard.

Ref: #319
2024-05-21 17:17:14 +02:00
Henrik Lissner
9c4a4cf058
fix(lib): remove-recent-file: improve completion UI
Integrates with completion frameworks (particularly vertico) that read
capf metadata.
2024-05-21 17:17:13 +02:00
Henrik Lissner
025bd6e17a
bump: :editor evil
emacs-evil/evil-collection@e0982fcbb6 -> emacs-evil/evil-collection@ca977acb83
emacs-evil/evil@88d073c9d0 -> emacs-evil/evil@0251080640

- Fixes #7798: corfu completion in minibuffer for Evil users (thanks to
  emacs-evil/evil-collection#801).

Fix: #7798
Ref: emacs-evil/evil-collection#801
2024-05-21 17:17:13 +02:00
gpanago
8d4e355af6
perf(tabs): rate limit centaur-tabs-buffer-update-groups
`centaur-tabs-buffer-update-groups` walks every buffer to determine the
group it belongs to. This function can be called execessively (upwards
of 1,000 times per second in certain conditions), as it is called on
every redisplay (it is indirectly attached to `tab-line-format`). This
rate limits its calls to about 10 per second.

Close: #7792
Ref: ema2159/centaur-tabs#222
2024-05-21 17:17:13 +02:00
StrawberryTea
1fbb78e92b
fix(vertico): missing command error in consult
Although it is rare for a user to not enable the :config default module,
enabling/disabling modules one-by-one is common practice for debugging
Doom Emacs. This PR fixes an error that occurs when you have :completion
vertico enabled without enabling :config default.
2024-05-21 17:17:13 +02:00
StrawberryTea
49cc3530d9
fix(corfu): prevent void-variable error
Although this error will not be triggered by most people, since
auth-source is loaded by a lot of packages, it can still happen if you
are debugging your configuration (e.g. enabling/disabling modules
one-by-one).
2024-05-21 17:17:13 +02:00
Henrik Lissner
26c70fd428
fix(vc): *vc-{diff,change-log}* popup rules
The former rules weren't proccing on these buffers. Also
changes *vc-diff* popups to resize based on contents.
2024-05-21 17:17:13 +02:00
Henrik Lissner
127f18101c
bump: :lang factor
factor/factor@23fcfc7075 -> factor/factor@12fc9d5071
2024-05-21 17:17:13 +02:00
Henrik Lissner
63615ffe4c
fix(factor): handle fuel popups
Fix: #7788
Co-authored-by: steve-ayerhart <steve-ayerhart@users.noreply.github.com>
2024-05-21 17:17:12 +02:00
Henrik Lissner
6de4e99d41
fix(factor): package association for lookup handlers & keybinds
This ensures all these fuel keybinds on factor-mode-map (and the
fuel-based lookup handlers) are associated with the fuel-mode
package (in case the user disables the fuel package).

Fix: #7788
Co-authored-by: steve-ayerhart <steve-ayerhart@users.noreply.github.com>
2024-05-21 17:17:12 +02:00
Henrik Lissner
f4ebe1a4c4
fix(factor): repl handler
Otherwise `+eval/open-repl-*` commands will emit "REPL handler X failed
to return a buffer" errors.

Fix: #7788
Co-authored-by: steve-ayerhart <steve-ayerhart@users.noreply.github.com>
2024-05-21 17:17:12 +02:00
Henrik Lissner
7d4b0d22dd
refactor(eval): avoid seq-uniq & cl-{first,second}
- While seq.el is likely present, Doom does not guarantee it in
  interactive sesions like it guarantees cl-lib's presence.
- There is no reason to ever use cl-first/cl-second.
2024-05-21 17:17:12 +02:00
Henrik Lissner
5bdfecfa92
feat(lib): sudo-{find,this}-file: invoke save-place
After switching to the sudo-ed tramp buffer, this restores the point and
scroll position of the window to match the source buffer.

I exploit save-place here instead of simply saving/restoring (point)
and (window-start), because I believe it's better UX that save-place
treat the two buffers as effectively the same now and in the future, and
record the last cursor position equally between them, even if the
implementation is messier. This *could* be generalized into an advice
for save-place-find-file-hook and save-place-to-alist, but that's an
experiment for another day.

This is an experimental implementation and may change later.

Close: #7181
Co-authored-by: YourFin <YourFin@users.noreply.github.com>
2024-05-21 17:17:12 +02:00
Henrik Lissner
c5d00f8217
fix(rust): lsp-mode: produce better hover info
The caching of rust-analyzer (RA) is too aggressive and leads to bad
results.

RA does not give a protocol-compliant way to extract 1 line information
from the hover response, so `lsp-mode` displays the first line of the
result, which currently is the byte alignment of the data

Fix: #6951
Close: #7754
Co-authored-by: gagbo <gagbo@users.noreply.github.com>
Co-authored-by: scturtle <scturtle@users.noreply.github.com>
2024-05-21 17:17:12 +02:00
Henrik Lissner
650e48837d
fix(mu4e): void-function mu4e-clear-caches error
mu4e-clear-caches was removed in djcb/mu@f73aad2b41, so users on
1.12.2 or so will see void-function errors until djcb/mu@770a2396de is
propagated to distro package managers, which likely won't happen
soon (esp for LTS distros).

Fix: #7703
Ref: djcb/mu@f73aad2b41
Ref: djcb/mu@770a2396de
Co-authored-by: dltacube <dltacube@users.noreply.github.com>
2024-05-21 17:17:12 +02:00
Henrik Lissner
6c65e9fa00
refactor: remove redundant auto-mode-alist entries
Also removes the *.{hex,nes} entry because it's far too niche to be a
global default.
2024-05-21 17:17:11 +02:00
Henrik Lissner
a4fc16d36f
refactor(corfu): use hook symbols in add-hook! calls
A common challenge for beginners is distinguishing packages, modes, and
hooks, and since Doom's source code is meant to second as another layer
of documentation, I prefer to be explicit with hook symbols in
`add-hook!` calls (at least, for internal/module use).
2024-05-21 17:17:11 +02:00
Henrik Lissner
f91d6beaa1
docs(julia): reformat & fix package/flag links 2024-05-21 17:17:11 +02:00
Henrik Lissner
e60b07e4e3
fix(julia): duplicate popup rules
Having the same rule in two separate package configs means users must be
aware of both to modify either, which is avoidable complexity. i.e.

  (after! (:or julia-repl julia-snail)
    (set-popup-rule! "^\\*julia" ...))
2024-05-21 17:17:11 +02:00
Henrik Lissner
d602a51091
bump: :tools pdf
vedang/pdf-tools@93e7492451 -> vedang/pdf-tools@a1048bceb2

- Fixes `pdf-tools-install` for users on MacOS
  Sonoma (vedang/pdf-tools#269).

Ref: vedang/pdf-tools#269
2024-05-21 17:17:11 +02:00
Henrik Lissner
b3287acbe0
refactor: doom--last-frame: remove unused symbol
Its last reference was removed in e889b2c. Not sure why this stuck
around for so long.

Ref: 0bb4d4dfcb
2024-05-21 17:17:11 +02:00
Henrik Lissner
d792f0dbb1
fix(lib): sudo-{find,this}-file: disable auto-save
auto-save can trigger processes that hang silently in the background,
making those buffers inoperable (hanging Emacs) for the rest of the
session, even if they are killed (tramp caches them), so I suppress them
solely for these temporary tramp buffers created by doom/sudo-find-file
and doom/sudo-this-file.
2024-05-21 17:17:11 +02:00
Henrik Lissner
4a9c71f96e
fix(web): make *.((s[ac]|le)ss|styl) siblings of *.css
I backported `find-sibling-file` in 198fe82 and included with it some
rudimentary `find-sibling-rules` rules for CSS and its various
preprocessor languages. The CSS rule made *.((s[ac]|le)ss|styl) files
the siblings of *.css files, but not vice versa, so users couldn't jump
back to the source file with `find-sibling-file`; a second rule is
necessary.

These may be combinable, considering `find-sibling-file` deletes the
current buffer's filename from the list of candidates...

Ref: 198fe82b6d49
2024-05-21 17:17:10 +02:00
Henrik Lissner
5c672b1d0e
fix(cc): make *.c(c|pp) siblings of *.h(h|pp) files
I backported `find-sibling-file` in 198fe82 and included with it some
rudimentary `find-sibling-rules` rules for C++ and others. The C++ rule
made *.h(h|pp) files the siblings of *.c(c|pp) files, but not vice
versa, so users couldn't jump back to the source file with
`find-sibling-file`; a second rule is necessary.

These may be combinable, considering `find-sibling-file` deletes the
current buffer's filename from the list of candidates...

Fix: #7795
Ref: 198fe82b6d49
2024-05-21 17:17:10 +02:00
Henrik Lissner
a37d801a48
fix(lib): find-subling-file-search: wrong-number-of-args error
I backported `find-sibling-file` from Emacs 29+ in 198fe82, but it
passes a third argument (REGEXP) to `file-expand-wildcards` which wasn't
introduced until 29, so users on 28 or earlier would see a
wrong-number-of-arguments error (see #7795).

Rather than backport the entire `file-expand-wildcards`
function (risking other edge cases), I've advised its usage in
`find-sibling-file-search` to behave as it would in 29+ with a non-nil
REGEXP argument.

Amend: 198fe82b6d49
Fix: #7795
2024-05-21 17:17:10 +02:00
Henrik Lissner
36c24be6d4
release(modules): 24.04.0-dev
Ref: 2b39e41368
2024-05-21 17:17:10 +02:00
Henrik Lissner
8a813dd3fa
refactor: startup optimizations
I revisit all our startup optimizations to see how they fair in Emacs
29.x and 30.x. Most of them still hold up. I've revised and updated most
of the accompanying comments to better explain them, given what I know
now compared to when I first wrote them.
2024-05-21 17:17:10 +02:00
Henrik Lissner
1ef499e923
fix(cli): doom upgrade: void-variable num
Fix: #7791
2024-05-21 17:17:10 +02:00
Henrik Lissner
472e00bc77
fix(org): org-download: remove unneeded advice
They've since been upstreamed in one form or another over time.

Fix: #7790
Ref: abo-abo/org-download@69c57bd519
Ref: abo-abo/org-download@8bc54b6c1a
2024-05-21 17:17:09 +02:00
Henrik Lissner
1a46aa05ea
bump: :term eshell
LemonBreezes/emacs-fish-completion@d34d0b96fd -> LemonBreezes/emacs-fish-completion@006c613ff7
akreisher/eshell-syntax-highlighting@4ac27eec65 -> akreisher/eshell-syntax-highlighting@1d25386bf7
peterwvj/eshell-up@ff84e6069b -> peterwvj/eshell-up@1999afaa50

Fix: #7789
2024-05-21 17:17:09 +02:00
Henrik Lissner
15d7353946
bump: :tools
andras-simonyi/citeproc-el@c61c98b9d2 -> andras-simonyi/citeproc-el@44f90cb296
editorconfig/editorconfig-emacs@c3666c093f -> editorconfig/editorconfig-emacs@d73b6392de
emacs-citar/citar-org-roam@7d67dccf80 -> emacs-citar/citar-org-roam@82d47b5df1
emacs-tree-sitter/tree-sitter-langs@c56cb51104 -> emacs-tree-sitter/tree-sitter-langs@b7895ca759
emacsorphanage/quickrun@248149b026 -> emacsorphanage/quickrun@373634cf51
hcl-emacs/terraform-mode@e8b57df8c2 -> hcl-emacs/terraform-mode@a645c32a8f
k1LoW/emacs-ansible@d89ac0ee57 -> k1LoW/emacs-ansible@1d7de8d3dd
krzysztof-magosa/company-ansible@79dd421b16 -> krzysztof-magosa/company-ansible@338922601c
nicolaisingh/saveplace-pdf-view@abfb5e1f46 -> nicolaisingh/saveplace-pdf-view@ee95460cd9
purcell/envrc@1385e72a73 -> purcell/envrc@8eb7401700
spotify/dockerfile-mode@52c6c00da1 -> spotify/dockerfile-mode@39a012a27f
tmalsburg/helm-bibtex@bf184cc311 -> tmalsburg/helm-bibtex@8b71b4f5ce
vedang/pdf-tools@c69e7656a4 -> vedang/pdf-tools@93e7492451
xuchunyang/osx-dictionary.el@1f5a74f3e5 -> xuchunyang/osx-dictionary.el@6abfd6908b
yoshiki/yaml-mode@5b58248ab2 -> yoshiki/yaml-mode@7b5ce294fb
2024-05-21 17:17:09 +02:00
Henrik Lissner
f33bd5bd63
bump: :completion
abo-abo/swiper@8c30f4cab5 -> abo-abo/swiper@1f88e54990
company-mode/company-mode@02903bd708 -> company-mode/company-mode@b0a522ac5b
emacs-helm/helm-descbinds@b725159823 -> emacs-helm/helm-descbinds@ca03f02da4
emacs-helm/helm@f34ea6b702 -> emacs-helm/helm@28f62344fe
minad/cape@a397a0c92d -> minad/cape@e01e443023
minad/consult@b48ff6bf05 -> minad/consult@c87b0bf06d
minad/corfu@c1e7b6190b -> minad/corfu@35cd5a0f3c
minad/marginalia@f6fe86b989 -> minad/marginalia@3275d1f85c
minad/vertico@68cbd47589 -> minad/vertico@68e51fda55
oantolin/embark@c93abadc82 -> oantolin/embark@d3c9d1b4c8
oantolin/orderless@dc7a781acf -> oantolin/orderless@ac4aeb66f3
radian-software/prescient.el@4b875be52e -> radian-software/prescient.el@c39bf07c56
sebastiencs/company-box@b6f53e26ad -> sebastiencs/company-box@c4f2e243fb
2024-05-21 17:17:09 +02:00
Henrik Lissner
efa76cda5b
bump: :tools magit :emacs vc
emacsmirror/git-timemachine@ac933e5cd2 -> emacsmirror/git-timemachine@5ed73c3831
magit/forge@2a3b41eb62 -> magit/forge@ad94b5665d
magit/magit@0e8f25a8d8 -> magit/magit@b5637d665c
2024-05-21 17:17:09 +02:00