Commit Graph

650 Commits

Author SHA1 Message Date
Maxime Coste
e8f26cbae7 Refactor write_buffer_to_file to use a flags param
That is clearer than two boolean parameters.
2019-02-12 20:18:34 +11:00
Maxime Coste
94796509a0 Fix bug in 'itersel' handling that could result in unsorted selections 2019-02-11 21:48:09 +11:00
Jan-Jaap Korpershoek
b171824d8b Add missing [<switches>] argument to declare-option 2019-01-25 00:03:20 +01:00
Maxime Coste
346c78f5e0 Header and dependency cleanup 2019-01-24 21:22:20 +11:00
Ivan Oleynikov
48249ea818
Very minor grammar fix
Probably, the extra «s» at the end of «exist» was added accidentally. A verb after «does not» in Present Simple definitely shouldn't have this extra «s».
2018-12-08 18:59:13 +03:00
Frank LENORMAND
f0e07cc73c src: Prevent :prompt -on-change from crashing the editor
Fixes #1217
2018-12-01 08:41:29 +03:00
Maxime Coste
8244087d45 Merge remote-tracking branch 'Delapouite/face-helper' 2018-11-27 18:18:18 +11:00
Delapouite
4c68abab11 doc: fix misc typos for source and region highlighter 2018-11-10 12:12:03 +01:00
Delapouite
22166a69c2 Add set-face/unset-face CommandHelpers 2018-11-09 08:29:16 +01:00
Maxime Coste
95622bc6e8 Merge remote-tracking branch 'Delapouite/debug-regex' 2018-11-06 20:17:41 +11:00
Delapouite
a61c6a9bb5 Truncate incomplete debug command docstring 2018-10-30 19:46:05 +01:00
Ruslan Prokopchuk
b65a6493aa replace usage of the deprecated 'e' face attribute with the new 'F' one
and update set-face docstring
2018-10-28 08:52:14 +11:00
Maxime Coste
dfc11d1c43 Refactor Hook management to have a well defined list of hooks
Hooks are now an enum class instead of passing strings around.
2018-10-23 08:15:53 +11:00
Delapouite
3a36490ef1 Add alias completer to unalias command 2018-10-08 22:07:13 +02:00
Justin Frank
ab6bc41358 Added shell command completion support to define-command and prompt
This commit also introduces a regression in that I decided that the best way to
avoid overly long and confusing names was to rename the current shell-*
switches to script-*, and have the shell command completion be
shell-completion.

renamed script-{completion,candidates} to shell-script-*

Updated docs with new switch names

Added -shell-completion switch to x11-repl and kitty-repl
2018-10-03 09:46:31 -07:00
Delapouite
b60613259c Add a way to unmap all keys of a given mode at once 2018-09-23 19:40:38 +02:00
Maxime Coste
9c1c763a37 Reject hook names that are not alphanumeric _ or - or start with -
Fixes #2414
2018-09-22 22:11:21 +10:00
Delapouite
d8747bc1e0 Add completion for rename-buffer, rename-client and rename-session 2018-09-20 19:01:47 +02:00
Maxime Coste
0c3d9ccd20 Change remove-hooks to take a regular expression
All hooks whose group match this regex will be removed.

Fixes #2380.
2018-09-12 21:26:21 +10:00
Maxime Coste
15bb23865a Join highlighter parameters with a '_' to autogenerate their name 2018-09-07 09:09:07 +10:00
Delapouite
5e75f748a2 docs: add missing -sync and exit status in autoinfo and doc page 2018-09-03 08:25:08 +02:00
Maxime Coste
df655422d1 Merge remote-tracking branch 'Screwtapello/support-user-map-options' 2018-08-30 20:10:00 +10:00
Maxime Coste
a0ac3c8c4c Merge remote-tracking branch 'occivink/source-with-args' 2018-08-30 20:04:07 +10:00
Maxime Coste
fcaa4314f7 Merge branch 'patch-1' of https://github.com/John-Colvin/kakoune 2018-08-30 20:03:51 +10:00
Shachaf Ben-Kiki
5238c2d93d Extend source command to support parameters.
Parameters are accessible in %arg{n}, as with define-command.
2018-08-30 10:00:13 +02:00
Maxime Coste
68aba9e353 Use shell specific quoting for env vars
Add a test case to validate roundtrips between Kakoune and the
shell.
2018-08-29 07:53:59 +10:00
John Colvin
94a3b85745 Missing space at eol in write CommandDesc 2018-08-28 11:59:43 +01:00
Frank LENORMAND
1da0af26c9 src: Make sure buffers are saved regardless of the client count
Due to a copy-paste mistake, the `:kill` command in a session with
multiple clients was the equivalent of a force-kill (`:kill!`).

This commit makes sure all buffers are saved before killing the
session, unless the force flag is specified.
2018-08-21 17:27:17 +03:00
Tim Allen
49ef9968c0 Support user-defined "str-to-str-map" options. 2018-08-21 18:24:14 +10:00
Maxime Coste
293610a432 Add a test case for -once hooks and code style tweaks 2018-08-16 21:09:51 +10:00
Maxime Coste
4387b1ac90 Merge remote-tracking branch 'lenormf/fix-hook-once' 2018-08-16 18:46:26 +10:00
Frank LENORMAND
97abfd403d src: Forbid empty menu entries
Empty entries in menus look weird, and don't serve any purpose. Empty
commands are still allowed.
2018-08-11 10:03:57 +03:00
Frank LENORMAND
e84dcf72c0 src: Allow hooks to be run only once
This commit implements the -once flag on the `:hook` command, which
automatically removes a hook after it was run, to avoid having to
declare a group and remove it in the hook implementation.

Closes #2277
2018-08-06 15:14:20 +03:00
Maxime Coste
d2509e54f2 Fix compilation with gcc-5
Gcc-5 seems to have a bug in its handling of template variable.

Fixes #2267
2018-07-30 07:15:17 +01:00
Maxime Coste
2c9daf2378 Merge remote-tracking branch 'Delapouite/map-key-completer' 2018-07-28 19:48:24 +10:00
Maxime Coste
bbb508634e Support setting registers to empty lists
Note that empty registers still act as-if they contained a single
empty string.

Fixes #2228
2018-07-23 08:35:13 +10:00
Maxime Coste
7195100609 Re-introduce kill_session::exit_status, @lenormf was right
As discussed in #2186, in the end we need the exit status for the
case where the local client exited first (the server forked to
background) then another client trigger the kill command.
2018-07-19 19:27:56 +10:00
Maxime Coste
56a5dc66ff Merge remote-tracking branch 'lenormf/kill-clients-exit-code' 2018-07-19 18:42:22 +10:00
Frank LENORMAND
5543a4d58c src: Propagate to clients the kill exit code
Fixes #2177
2018-07-19 10:54:49 +03:00
Maxime Coste
56912dd22c Merge remote-tracking branch 'icetan/buffer-reload-hook' 2018-07-19 08:29:22 +10:00
Maxime Coste
b1d5fda960 Reduce confusion in add-highlighter docstring
Closes #2222
2018-07-19 08:26:25 +10:00
Maxime Coste
2f815511da Merge remote-tracking branch 'Screwtapello/fix-info-docstring' 2018-07-14 23:17:10 +10:00
Tim Allen
591a9ab093 The info command only takes one content string, not one-or-more. 2018-07-10 17:51:57 +10:00
Christopher Fredén
ae6c214f52
Add BufReload hook which is triggered on buffer reload 2018-07-09 14:20:52 +02:00
Maxime Coste
51ec1194f1 Use a memory mapped file for sourcing 2018-07-08 17:25:12 +10:00
Maxime Coste
f89ea657ef Fix asserts with -sync flag handling and slight code cleanup 2018-07-05 08:30:57 +10:00
Maxime Coste
55a5ec3bbd Tweak how highlighter names are auto-generated 2018-07-05 07:54:28 +10:00
Maxime Coste
f9fda70de6 Fix add-highlighter docstring 2018-07-05 07:54:28 +10:00
Maxime Coste
073b630e7a Prevent adding region/default-region highlighters to non-regions parents 2018-07-05 07:54:28 +10:00
Maxime Coste
64d0fd91ae Auto-generate highlighter name if only path is given 2018-07-05 07:54:28 +10:00