Commit graph

19440 commits

Author SHA1 Message Date
Henrik Lissner
498966179f
perf(cli): doom: reduce init time
Even `emacs --batch -f kill-emacs` can take a non-trivial amount of time
to start up (0.661s on my system). This makes the two `emacs` calls in
bin/doom's shebang amount to >1s of startup time for Doom scripts (~1.5s
on my system). This change removes the second call (or at least defers
it until the after-script; at least, if $TMPDIR or $TEMP aren't set),
bringing down that time to a more bearable 0.9s.

This sacrifices the more descriptive "Can't find Emacs in your $PATH"
error message should the user set their own $EMACS, but the alternative
bash error is good enough:

  $ EMACS=foo doom version
  /home/$USER/.config/emacs/bin/doom: line 12: foo: command not found

I'm not doing more sophisticated checks on $EMACS, because it could be a
command (like `flatpak run org.gnu.emacs`), rather than an executable or
path, and the boilerplate to handle that, within what small space we get
in bin/doom's shebang, would be too much maintenance headache just for a
slightly better error message.
2024-09-10 00:06:03 -04:00
Henrik Lissner
98e28d801e
fix(indent-guides): don't activate in noninteractive sessions
Such as when `doom doctor` loads Doom.

Fix: #8058
2024-09-09 20:18:13 -04:00
Henrik Lissner
b03e78918b
bump: org-contacts ob-php
https://repo.or.cz/org-contacts.git@f0a430442b2a -> doomelpa/org-contacts@f0a430442b
https://repo.or.cz/ob-php.git@6ebf7799e9de -> doomelpa/org-contacts@6ebf7799e9

Moved these packages to a more stable host.
2024-09-09 20:15:43 -04:00
Henrik Lissner
9d172f8c25
feat(default): bind '<leader> o /' to dirvish
Use the prefix arg to prompt for a directory first.
2024-09-09 18:53:57 -04:00
Henrik Lissner
47c8c905b8
feat(dired): open dirvish sidebar w/ '<leader> o {p,P}'
A new alternative to neotree and treemacs.
2024-09-09 18:52:45 -04:00
Henrik Lissner
07eae64509
refactor(vc): move git-commit to magit module
`git-commit` is no longer distributed with `magit` and no longer
declares its dependencies, causing "file missing: with-editor" and
similar errors for folks who don't have magit installed. Also, VC's
commit workflows don't utilize the mode, so there's no reason to keep it
in this module.

Ref: magit/magit@c170fcf399
Ref: #8003
2024-09-09 18:08:28 -04:00
Henrik Lissner
bbb2cc1cb3
fix(indent-guides): disable indent-bars in tree-sitter-mode
A temporary measure, until the tree-sitter module has adopted treesit,
which indent-bars has support for.
2024-09-09 17:24:45 -04:00
Henrik Lissner
005831bfcc
refactor(lsp): let lsp-mode load lsp client packages
Most of these lsp packages are already in `lsp-client-packages`, which
lsp-mode will eagerly load the first time `lsp-mode` is activated, so we
don't need to do it ourselves, except in cases where the package isn't
in `lsp-client-packages` (like lsp-julia).
2024-09-09 17:24:45 -04:00
Henrik Lissner
374c28cedd
refactor(cc): only bind ccls keys if ccls is present
Fix: #5597
2024-09-09 17:24:45 -04:00
Henrik Lissner
cc8cf810f5
tweak(cc): prioritize clangd over ccls
lsp-clangd's default priority is -1.

Fix: #2689
2024-09-09 16:10:34 -04:00
Henrik Lissner
1a33838423
refactor!(cc): remove irony and rtags
BREAKING CHANGE: This removes the irony and rtags packages so we can
lean on LSP servers like clangd and ccls fully, which provide the same
features with much more consistency.

Close: #8049
2024-09-09 16:10:19 -04:00
Henrik Lissner
01c19094e8
fix(python): type error if conda-anaconda-home is unset
Amend: 8f60a1bc46
2024-09-09 14:39:44 -04:00
Henrik Lissner
632a091abb
refactor: remove unneeded optimizations
Neither of these have had enough/any impact on runtime performance to
warrant keeping them.
2024-09-09 00:35:57 -04:00
Henrik Lissner
bcdb945465
fix(indent-guides): interop with magit-blame
Ref: af814ff86a
Ref: #8052
2024-09-09 00:35:57 -04:00
Henrik Lissner
af814ff86a
fix(indent-guides): interop with lsp-ui-peek
Ref: #8052
2024-09-08 17:54:18 -04:00
Henrik Lissner
0461c5de5f
tweak(indent-guides): subtle bars & bitmaps (almost) by default
In e0a926d, I defaulted to not using bitmaps for indent-guides, but
after some more research, I realize this slowness is more prominent on
MacOS, older PGTK builds, and (possibly) Windows, so I've opted to
re-enable bitmaps by default, unless you're on one of those
systems (except Windows; still testing that).

This change also makes the guide bars more subtle, since the default is
too distracting and colorful.

Ref: #8052
Ref: e0a926dc1e
2024-09-07 22:41:53 -04:00
Henrik Lissner
0dc1084e8a
bump: :lang
ProofGeneral/PG@99f91e873e -> ProofGeneral/PG@3a99da2755
agda/agda@fbf9d159c3 -> agda/agda@4f82f9b90a
amake/flutter.el@004c91e070 -> amake/flutter.el@e71235d400
babashka/neil@a38be9f082 -> babashka/neil@6728367eff
beancount/beancount-mode@71c1622246 -> beancount/beancount-mode@7b437abcf0
chachi/cuda-mode@7dd07a20c3 -> chachi/cuda-mode@c3dae31b3d
clojure-emacs/cider@105da319b0 -> clojure-emacs/cider@8fdb53e8be
dominikh/go-mode.el@636d36e37a -> dominikh/go-mode.el@602d73e226
emacs-geiser/geiser@b6b4ac070d -> emacs-geiser/geiser@97ce88463f
emacs-geiser/guile@d5175439c0 -> emacs-geiser/guile@5a856c2982
emacs-gnuplot/gnuplot@7138b139d2 -> emacs-gnuplot/gnuplot@4c6b18f71f
emacs-lsp/lsp-dart@1f52e81c93 -> emacs-lsp/lsp-dart@9ffbafb7dc
emacs-lsp/lsp-haskell@18a7c7881f -> emacs-lsp/lsp-haskell@ba49fa9822
emacs-lsp/lsp-java@4909c14b90 -> emacs-lsp/lsp-java@868600bf7f
emacs-lsp/lsp-metals@fa4072cbe7 -> emacs-lsp/lsp-metals@0dc938be11
emacs-lsp/lsp-sourcekit@bb2b7e0278 -> emacs-lsp/lsp-sourcekit@63ff1ab638
emacs-lsp/lsp-treemacs@1d43e9e030 -> emacs-lsp/lsp-treemacs@fb1a07ae0a
emacs-straight/adaptive-wrap@f5bc153273 -> emacs-straight/adaptive-wrap@d75665b9c8
emacs-straight/auctex@451b0f08b0 -> emacs-straight/auctex@08881d08ce
emacs-straight/csv-mode@cdb73a771b -> emacs-straight/csv-mode@6979fc18eb
emacs-straight/org-mode@f398724bd5 -> emacs-straight/org-mode@6a5d0ed342
emacs-straight/rainbow-mode@0740f31f30 -> emacs-straight/rainbow-mode@2e6b18609c
emacs-straight/sml-mode@d114e5a27f -> emacs-straight/sml-mode@021233f60a
emacsmirror/paredit@9a2c4b37fc -> emacsmirror/paredit@037b9b8acb
ericdallo/jet.el@7d5157aac6 -> ericdallo/jet.el@c9a92675ef
erlang/otp@2a64588d4a -> erlang/otp@c66bf53cde
factor/factor@d143007778 -> factor/factor@31dc1a386b
fosskers/sly-overlay@4c6135c260 -> fosskers/sly-overlay@d629450590
fxbois/web-mode@005aa62d6f -> fxbois/web-mode@0c83581d1e
gcv/julia-snail@f7784c5007 -> gcv/julia-snail@dff92c4250
greghendershott/racket-mode@40ecb87f40 -> greghendershott/racket-mode@dba66c4536
hhvm/hack-mode@ccf20511f0 -> hhvm/hack-mode@343e45f2a6
https://repo.or.cz/org-contacts.git@d0cb221502c9 -> https://repo.or.cz/org-contacts.git@f0a430442b2a
hvesalai/emacs-scala-mode@4c6d636b86 -> hvesalai/emacs-scala-mode@bd0638c32a
idris-hackers/idris-mode@38dd2380dc -> idris-hackers/idris-mode@09de86a8f0
ifitzpatrick/graphql-doc.el@d37140267e -> ifitzpatrick/graphql-doc.el@17755a2466
jart/disaster@16bba9afb9 -> jart/disaster@b20f8e1ef9
joaotavora/sly@ba40c8f054 -> joaotavora/sly@742355f755
jorgenschaefer/emacs-buttercup@a1a86b027f -> jorgenschaefer/emacs-buttercup@bf01a33f8b
jrblevin/markdown-mode@8aab017f47 -> jrblevin/markdown-mode@6102ac5b73
jschaf/powershell.el@f2da15857e -> jschaf/powershell.el@38727f1cda
jwiegley/emacs-async@f317b0c9c3 -> jwiegley/emacs-async@43f97d7e68
ledger/ledger-mode@b0e65f74a5 -> ledger/ledger-mode@a6be7a2d79
nonsequitur/inf-ruby@0cfe8b2fb1 -> nonsequitur/inf-ruby@b234625c85
ocaml/dune@96ed5fb42f -> ocaml/dune@a7924e322e
ocaml/merlin@9fa77dbe81 -> ocaml/merlin@e016abfac6
oer/org-re-reveal@dbd8ffb3e5 -> oer/org-re-reveal@91610ba9b0
org-noter/org-noter@68646b685a -> org-noter/org-noter@6f292d7f1e
org-roam/org-roam@8667e44187 -> org-roam/org-roam@0b9fcbc97b
rust-lang/rust-mode@a529a45181 -> rust-lang/rust-mode@c87f6f82bd
seagle0128/grip-mode@7c42b8f61d -> seagle0128/grip-mode@9adac9c989
technomancy/fennel-mode@a4ddd1750f -> technomancy/fennel-mode@f4bd34e1c3

From this point on, Org will be pinned to tagged releases.
2024-09-07 19:04:37 -04:00
Henrik Lissner
2fa4faa6cd
bump: :tools
emacs-citar/citar@07d2a63c99 -> emacs-citar/citar@0f1786b7fe
emacs-lsp/lsp-mode@12befaabe4 -> emacs-lsp/lsp-mode@dd61303b2d
emacs-straight/eglot@3a5240d8fd -> emacs-straight/eglot@6b9c4faa52
emacs-tree-sitter/tree-sitter-langs@1c3d95d018 -> emacs-tree-sitter/tree-sitter-langs@365a4f7bf5
magit/forge@35cc600d62 -> magit/forge@d4e88507bf
meain/evil-textobj-tree-sitter@041fcb9fbb -> meain/evil-textobj-tree-sitter@b4ef204ff8
tumashu/posframe@493b17f74a -> tumashu/posframe@570273bcf6

From this point on, Doom will be bumping magit and forge to tagged
releases.
2024-09-07 19:04:37 -04:00
Henrik Lissner
737f91242a
bump: :editor evil
emacs-evil/evil-collection@772571fc67 -> emacs-evil/evil-collection@6365e7c8ae

Revert: 9d7885abbf
Ref: emacs-evil/evil-collection#833
2024-09-07 19:04:37 -04:00
Henrik Lissner
871efdce08
refactor: windows: move doom dirs to %LOCALAPPDATA%
More appropriate location for these files on Windows than %APPDATA%.
2024-09-07 19:04:37 -04:00
Henrik Lissner
6025e141aa
perf(lib): minor optimizations
To reduce allocations in hot loops.
2024-09-07 19:04:37 -04:00
Henrik Lissner
0d9e188b26
refactor!(indent-guides): use indent-bars instead
BREAKING CHANGE: This swaps out the `highlight-indent-guides` package
with the newer, and proportedly faster, `indent-bars`. Users don't have
to make any changes to their config to support this, unless they've
heavily reconfigured `highlight-indent-guides`.

Ref: https://github.com/orgs/doomemacs/projects/5/views/1?filterQuery=-status%3ARejected%2CDone+indent&pane=issue&itemId=38113671
2024-09-07 19:04:37 -04:00
Eleanor Bartle
ac1122ae67
tweak(erlang): format w/ erlfmt instead of efmt 2024-09-07 15:11:43 -04:00
gpanago
ed05e4c088 feat(nav-flash): blink on workspace change
Changing workspace is big motion so we should blink the cursor.
We can not use `+nav-flash-blink-cursor-maybe-h` as the point
is not yet in the correct buffer when the hook is triggered.
2024-09-07 12:10:41 -07:00
Puneeth Chaganti
765f317427
docs(magit): remove magit-todos from the README
0893ede removed magit-todos from the default magit module configuration.
Users are expected to install it by themselves, if they wish to use the
package, given it's simple config.

Amend: 0893edefae
2024-09-07 15:10:11 -04:00
Henrik Lissner
de1ffbca11
feat: distinguish [C-m] key from RET
Now, uses can rebind ctrl+m by targeting [C-m] (or "<C-m>", same thing),
and it won't rebind RET. This will only work in GUI Emacs, however, and
there is no kkp support for this one.

Ref: 96d7e50f3e
2024-09-07 14:50:32 -04:00
Henrik Lissner
4fc11b696e
tweak: projectile: don't follow symlinks by default
Experienced users (the type to use symlinks in their projects) can add
-L back to `projectile-git-fd-args`, otherwise, its poorer UX for
beginners if Projectile indexes symlinked build artifacts (like 'result'
symlinks by Nix); i.e. things they didn't symlink themselves.

Fix: #7781
2024-09-07 14:20:29 -04:00
Henrik Lissner
1ff37f9fa4
fix(dired): preserve buffers on dirvish-find-entry-a
Fix: #8038
2024-09-07 13:57:58 -04:00
Henrik Lissner
2d3821741a
refactor(cli): introduce doom-cli-shell
Instead of constantly checking $__DOOMSH, since I may eventually add
additional values for it (like in the cases where the doom script is
invoked by bin/doomscript, from a terminal emulator in Emacs, or future
wrappers).
2024-09-07 13:52:25 -04:00
Henrik Lissner
2981aec4dd
fix(lib): doom/{reload,upgrade}: double-escaped %s in command
Amend: f644c4fa6c
2024-09-07 13:51:21 -04:00
Henrik Lissner
73ab554566
fix(cli): don't auto-invoke pager under powershell
Need to find a pager that works on Windows.
2024-09-07 04:03:02 -04:00
Henrik Lissner
94a291a7f8
fix(cli): doom.ps1: path to post-script 2024-09-07 02:51:12 -04:00
Henrik Lissner
4c7aec35ba
fix(cli): envvar injection into bin/doom post-script 2024-09-07 02:42:34 -04:00
Henrik Lissner
61dc1da645
fix(cli): doom.ps1: interpolated variable in error message 2024-09-07 01:20:37 -04:00
Henrik Lissner
f644c4fa6c
feat: add basic android support 2024-09-07 01:06:33 -04:00
Henrik Lissner
8d2cf32fef
feat(cli): add doom.ps1 for Windows users
c9acdb7 removes doom.cmd because it was broken in most cases. This adds
doom.ps1; an alternative script for Windows+Powershell users, which
properly initializes the state it needs. Naturally, it requires
Powershell 3+ be installed on your systems, but it can be invoked from
either cmd.exe or PowerShell.exe.

This is the first powershell script I've ever written, so I expect edge
cases (for one, shell commands passed to `exit!` will need to be guarded
against the environment).

This also requires emacs.exe be your $PATH, however, unless you set
$EMACS to its path first. E.g.

  $env:EMACS = "C:\Program Files\Emacs\emacs-29.4\bin\emacs.exe"

That said, if you use WSL2, you're still far better off using the bash
script (bin/doom).

Ref: c9acdb72a4
2024-09-07 01:05:57 -04:00
Henrik Lissner
9753bfb775
fix: {back,fore}ground-color in subsequent frames
New frames created after the first get initialized with #000000 as their
{back,fore}ground-color parameters, for some reason, making text
unreadable in dark themes.
2024-09-07 01:05:57 -04:00
Henrik Lissner
e0a926dc1e
tweak(indent-guides): default to character method
The bitmap method is slower and not that different, visually, from the
character method.

Fix: #8052
Co-authored-by: nightkr <nightkr@users.noreply.github.com>
2024-09-06 16:15:57 -04:00
Henrik Lissner
79684ade71
fix(latex): run after-compilation-finished hook after Tex-Tex-sentinel
Fix: #8051
2024-09-06 04:46:36 -04:00
Henrik Lissner
fe54aa436c
fix(latex): modes not remapped to auctex modes
Deduced from a comment in 21a252d (where
`TeX-after-compilation-finished-functions` wasn't being triggered
because the user was in latex-mode, instead of LaTeX-mode).

Fix: 21a252d994
2024-09-05 16:01:03 -04:00
Henrik Lissner
6d9a7e9a8f
fix: over-aggressive deactivation of hl-line-mode
`(de?)activate-mark-hook` is triggered a little too often in too many
edge cases where the user isn't interactively selecting a region. One
annoying edge case has non-evil motions used on evil operators
activating but not deactivating the mark (e.g. #8047).

This leaves non-evil users without the nicety of hl-line auto-disabling
itself when the region is active, but I'll revisit that in v3.0, when
most of these package defaults are moved out to modules.

Fix: #8047
2024-09-05 15:30:22 -04:00
Henrik Lissner
45310f1c3e
fix(mu4e): "no such file or directory: ~/.mbsyncrc"
In c647957 "~/.mbsyncrc" was passed to mbsync quoted, preventing ~ from
being expanded into $HOME. Now, I've chosen to omit the whole --config
option if $XDG_CONFIG_HOME/isyncrc isn't present, since mbsync will fall
back to ~/.mbsyncrc on its own.

Amend: c6479574e6
Fix: #8048
2024-09-05 15:30:22 -04:00
Henrik Lissner
03e5f1333c
fix(latex): reorder viewers wrt +latex-viewers
If a viewer already exists in `TeX-view-program-selection`, loading
`+viewer.el` does not change its order because `add-to-list` does
nothing when the item is already in the list.

Close: #8046
Fix: #5275
Co-authored-by: cartoonist <cartoonist@users.noreply.github.com>
2024-09-05 15:30:22 -04:00
Henrik Lissner
1fa1eba5ac
bump: :lang python
emacs-lsp/lsp-pyright@cc6df06aea -> emacs-lsp/lsp-pyright@0c0d72aedd
necaris/conda.el@60e14d1e97 -> necaris/conda.el@ce748a53f9
pythonic-emacs/anaconda-mode@79fa9b4d2b -> pythonic-emacs/anaconda-mode@f900bd7656
pythonic-emacs/company-anaconda@1fe526163c -> pythonic-emacs/company-anaconda@169252fca7
pythonic-emacs/pyenv-mode@de0d750b9c -> pythonic-emacs/pyenv-mode@76787ea44f
wbolster/emacs-python-pytest@9f850e22df -> wbolster/emacs-python-pytest@dcdaec6fe2

- Adds basedpyright support to lsp-pyright; and will prioritize it above
  pyright, if found on your system.

Ref: emacs-lsp/lsp-pyright#101
2024-09-05 15:30:22 -04:00
Henrik Lissner
424b7af45f
fix(mu4e): duplicate "view in browser" actions
These are already present in newer versions of mu4e. By making them
match, `add-to-list` won't add a duplicate.

Fix: #6328
2024-09-05 04:27:20 -04:00
Henrik Lissner
c6479574e6
feat(mu4e): respect XDG for mbsync config file
Support for this was only added in isync 1.5, but this way, users on
older can benefit from it through Emacs.

Ref: cf13630a00/
2024-09-05 04:21:58 -04:00
Henrik Lissner
139591172e
fix(mu4e): add mu4e-debug to doom-debug-variables 2024-09-05 04:21:58 -04:00
Henrik Lissner
5c0211d635
refactor(mu4e): mu4e config
In preparation for all the work I have in store for this module.
2024-09-05 04:21:58 -04:00
Henrik Lissner
60e94479a7
feat(mu4e): add mu4e-compat package
(And remove vestigial ref to mu4e-alert in docs)

Fix: #6906
Fix: #7860
2024-09-05 04:21:57 -04:00
Henrik Lissner
48a6b30f48
refactor(mu4e): replace +mu4e-backend w/ +offlineimap/+mbsync flags
`+mu4e-backend` is now deprecated and will be removed in v3.0.
2024-09-05 04:20:28 -04:00