Henrik Lissner
0bb4d4dfcb
refactor: switch buffer/frame/window hooks
...
Emacs 27 introduced a bunch of `window-*-change-functions` hooks,
including `window-selection-change-functions` and
`window-buffer-change-functions`, which handles 98% of the use case for
Doom's `doom-switch-{buffer,window,frame}-hook` hooks, so I've rewritten
them to use them under the hood, which amounts to simpler code and fewer
hacks.
2021-10-10 18:36:46 +02:00
Henrik Lissner
45c759d7d7
fix(evil): evil-join fails to join commented lines
...
Fix #5558
2021-10-05 02:33:15 +02:00
Henrik Lissner
06392a723f
refactor: rename orig-fn arg in advice to fn
...
A minor tweak to our naming conventions for the first argument of an
:around advice.
2021-08-04 01:53:12 -04:00
Henrik Lissner
bd94250503
Fix #5113 : "defining as dynamic an already lexical var" error
...
Due to a dynamic variable being let-bound while evil-textobj-anyblock is
loading, so load it first.
2021-05-30 12:21:13 -04:00
Benjamin Picardat
e33b21dc46
Fix #4770 : New window is focused after split
...
According to the documentation of `evil-window-split` the variable
`evil-split-window-below` needs to be non-nil for the new window to be
created below; and for `evil-window-vsplit` it is the variable
`evil-vsplit-window-right` that needs to be non-nil for the window to be
created on the right.
2021-03-10 15:48:31 +01:00
Henrik Lissner
2a4509c42a
editor/evil: fix typo in +evil-window-split-and-follow
...
And conform these commands to naming conventions.
2021-03-06 10:31:10 -05:00
Henrik Lissner
0917187f20
editor/evil: bind C-w {S,V} to split-and-follow
2021-03-06 09:59:50 -05:00
Henrik Lissner
c049480cbd
Fix evil-join filling non-comments poorly
2021-02-25 13:59:43 -05:00
Janfel
6c163d77d9
Fix +evil:retab
2021-02-02 02:38:12 +01:00
Saulius Menkevicius
198712060a
Fix +evil--insert-new-line advice when opening new line inside a comment.
...
`comment-line-break-function` requires a single `soft-newlines` argument.
2021-01-17 15:53:23 +02:00
Henrik Lissner
6970903a43
Fix #4465 : >,< not shifting whole lines
...
This fixes make > and < behave as it does in vim in regular visual mode.
2021-01-03 17:18:43 -05:00
Henrik Lissner
765b6dcfca
Unset unused markers
...
In case of overlay leaks.
2020-12-12 15:56:36 -05:00
Henrik Lissner
d149c59d2e
Add emacs mode checks to insert mode checks
...
This is to accommodate users who default to emacs mode, rather than
insert mode. The two are also very alike, so many of these checks should
apply to both (almost) equally.
2020-12-11 17:38:09 -05:00
Erlend Hamberg
d21d86aafc
Add single quotes to ‘any quote’ text objects
2020-10-28 08:48:01 +01:00
Henrik Lissner
164b997cb0
Add q text-object for all quotes
2020-10-27 23:18:06 -04:00
Henrik Lissner
40cf6139ed
Make evil-join remove comment delimiters
...
See emacs-evil/evil#606
2020-08-09 01:50:41 -04:00
Henrik Lissner
d12752324a
Introduce letf! convenience macro
...
A more succinct cl-letf, which allows for local functions and macros.
2020-04-29 23:48:21 -04:00
Henrik Lissner
c1127a5bde
Rewrite move/copy/delete file commands
...
To use rename-file, copy-file and delete-file, so these commands can
enjoy the benefits of any plugins that have advised these, like org-roam
does for rename-file.
2020-04-27 01:51:18 -04:00
Henrik Lissner
50ff934ff2
Fix #2832 : filename modifiers replaced with empty strings
2020-04-26 04:12:33 -04:00
Henrik Lissner
bce0cc2152
Change how evil-easymotion is lazy loaded
...
Fixes an issue where gs wouldn't work after an operator.
2020-04-14 15:41:54 -04:00
Oskar Kvist
427ed2bbc0
Fix +evil:defun-txtobj docstring
2020-03-23 18:23:22 +01:00
yoavm448
fcac85fc86
Make +evil:copy-this-file autoload interactively
2020-03-03 20:02:07 +02:00
Henrik Lissner
888d456dc9
Fix #2524 : :make executing wrong command
2020-02-20 17:42:58 -05:00
Henrik Lissner
dbf9c92b48
Fix +evil-resolve-vim-path-a not removing excess backslashes
2020-02-20 00:51:55 -05:00
Henrik Lissner
1575300ad4
Add iu/au text-object for urls #2484
2020-02-04 13:58:43 -05:00
Henrik Lissner
fe0c5e135d
Fix #2293 : easymotion with evil operators
...
Reverts fix for #1672 , but provides a workaround:
(map! :n "gl" (λ! (+evil/easymotion 'normal 'global)))
2020-01-28 17:50:11 -05:00
Henrik Lissner
1b779bf716
Fix evil ex fname modifiers consuming char just before #/%
...
':e test-%:t.el' in filename.el should open test-filename.el, but
instead opened testfilename.el.
2020-01-20 19:14:25 -05:00
Henrik Lissner
dcb0b6042e
Ensure evil-easymotion is lazy-loaded
...
The evilem-create calls were pulling it in early, at startup.
2019-12-27 01:54:01 -05:00
Henrik Lissner
d1f4a77fbb
Fix vestigial reference to old help-search-headings fn
2019-12-26 16:50:49 -05:00
Henrik Lissner
adc8cba14b
Revise docstrings & minor reformatting
2019-12-26 01:41:44 -05:00
Henrik Lissner
baae6b1711
Rename +evil/paste-preserve-register => +evil/alt-paste
...
Now does the invers of evil-kill-on-visual-paste
2019-12-21 03:59:46 -05:00
Henrik Lissner
27cabea6b6
Fix gs in org-mode #2218
...
Also makes +evil/easymotion generic; it can now be moved to any key, and
new keys can be added to the <easymotion> event, rather than having to
wait for evilem-map to become available.
Also fixes +org/goto-visible if used before avy is loaded.
Relevant to #1672
2019-12-20 13:40:06 -05:00
Brian Wignall
199a6fab79
Fix typos
2019-12-01 22:31:19 -05:00
Henrik Lissner
26c8f5c6ef
Bytecompiler bytecompiler, won't you shut up
2019-11-23 01:21:25 -05:00
Henrik Lissner
449ddb986c
Minor refactors & reformatting across the board
2019-11-15 22:17:31 -05:00
Henrik Lissner
03e9dc1daf
Follow up on 64222c69c
...
To fix cases where comment-line-break-function's first argument isn't
optional.
2019-11-15 22:17:31 -05:00
Henrik Lissner
46bea60ad3
Add :Read ex command & 'SPC i p' keybind
...
This can be used to extract paths from evil-ex style paths. e.g. the
following inserts the stdout into the current buffer (assuming we're in
~/some/project/filename.c):
:R!echo %:P ~/some/project
:R!echo %:t filename.c
:R!echo %:e c
:R!echo %:r filename
:R!echo ~/another/project/%:t:r.h
~/another/project/filename.h
:R % contents of current file
http://vimdoc.sourceforge.net/htmldoc/cmdline.html#filename-modifiers
has a full list of vim filename modifiers. Doom doesn't support all of
them, but it does support most of them.
2019-11-15 22:17:30 -05:00
Henrik Lissner
1d09e4655a
Fix split-window & update docstring
2019-10-29 18:27:19 -04:00
Henrik Lissner
43030c789e
editor/evil: revert focus-on-split behavior (and refactor advice)
...
Focus-on-split is being disabled to achieve vim parity. The advice is
still necessary to ensure splitting updates the window buffer list, so
operations like winner-undo undoes correctly.
2019-10-29 01:09:14 -04:00
Henrik Lissner
9e2b0c6332
editor/evil: fix autoload for +evil:whole-buffer-textobj
2019-10-28 23:23:13 -04:00
Henrik Lissner
83387d89e9
editor/evil: move vim-unimpaired motions
...
To the unimpaired library
2019-10-26 00:37:51 -04:00
Henrik Lissner
f2b77fe2c0
Add whole-buffer (g) and defun (f) text objects
2019-10-26 00:37:12 -04:00
Henrik Lissner
7654764713
editor/evil: update docstring for +evil:align* commands
2019-10-10 21:38:08 -04:00
Henrik Lissner
aac843511b
Fix :h[elp] ex command
...
To now open documentation for ex commands, otherwise falling back to
apropos. If BANG, then searches Doom's (yet to be published) manual.
2019-10-10 21:31:13 -04:00
Henrik Lissner
a3fa1e07b1
Refactor doom/kill-*-buffer commands
2019-10-10 16:11:42 -04:00
Henrik Lissner
07380af819
Add gy operator for yanking without indentation
...
Copies
(a
b
c)
As
(a
b
c)
2019-10-10 16:11:41 -04:00
Henrik Lissner
e10cd8cf2e
Insult byte-compiler's mom
...
Yeah, that shut him up.
2019-09-20 23:10:53 -04:00
Henrik Lissner
ab8b31e5bc
Change behavior of BANG for +evil:narrow-buffer
...
BANG = use indirect buffers, otherwise, narrow/widen the current buffer.
2019-09-14 18:32:14 -04:00
Henrik Lissner
20d15c685e
Fix :narrow ex command
2019-09-14 01:56:38 -04:00
Henrik Lissner
c8baa2b3f6
editor/evil: refactor ex commands; add evil-traces
...
This commit lazy loads Doom's custom ex commands. To add your own,
you'll need to wrap them in (after! evil-ex ...).
2019-08-15 14:58:41 -04:00