| Commit message (Collapse) | Author | Age |
|
|
|
|
|
|
|
| |
I don't think using an integer as a NUL-terminated string can work on
big-endian systems, at least.
This is also not tested. Add a test.
Also fix a mistake in the docs of nvim_parse_cmd.
|
|
|
|
|
|
| |
Now nvim_parse_cmd and nvim_create_user_command use a "tab" value which
is the same as the number passed before :tab modifier instead of the
number plus 1, and "tab" value is -1 if :tab modifier is not used.
|
| |
|
| |
|
|
|
|
|
|
|
| |
Problem: A command defined with `nargs="?"` returns `fargs={""}` to
a Lua callback when executed with no arguments, which is inconsistent
with how`nargs="*"` behaves.
Solution: Pass `fargs={}` for no argument with `nargs="?"` as well.
|
| |
|
|
|
|
| |
Closes #18876.
|
|
|
|
| |
Adds a Lua-only `preview` flag to user commands which allows the command to be incrementally previewed like `:substitute` when 'inccommand' is set.
|
|
|
|
|
|
|
| |
Adds an `smods` key to `nvim_create_user_command` Lua command callbacks,
which has command modifiers but in a structured format. This removes the
need to manually parse command modifiers. It also reduces friction in
using `nvim_cmd` inside a Lua command callback.
|
|
|
|
|
| |
Skip runs of whitespace and do not include `\` characters when
followed by another `\` or whitespace. This matches the behavior
of <f-args> when used with `:command`.
|
| |
|
|
|
|
|
|
|
|
| |
helpers.source() was a hack to work around the lack of anonymous
:source. Its "create tempfile" behavior is not a required part of most
tests that use it.
Some tests still need the old "create tempfile" behavior either because
they test SID behavior, or because of missing nvim_exec features: #16071
|
|
|
|
|
| |
Works similar to ex <f-args>. It only splits the arguments if the
command has more than one posible argument. In cases were the command
can only have 1 argument opts.fargs = { opts.args }
|
|
|
|
| |
This uses the same validation used when defining commands with
`:command`.
|
|
|
|
|
|
|
|
| |
Problem: "verbose set efm" reports the location of the :compiler command.
(Gary Johnson)
Solution: Add the "-keepscript" argument to :command and use it when
defining CompilerSet.
https://github.com/vim/vim/commit/58ef8a31d7087d495ab1582be5b7a22796ac2451
|
|
|
|
|
| |
Add support for adding and removing custom user commands with the Nvim
API.
|
|
|
|
|
|
|
| |
Do not copy a lot of lua strings (dict keys) to just strequal() them
Just compare them directly to a dedicated hash function.
feat(generators): HASHY McHASHFACE
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Problem: No error when using :complete for :command without -nargs.
Solution: Give an error. (Martin Tournoij, closes vim/vim#8544, closes vim/vim#8541)
https://github.com/vim/vim/commit/de69a7353e9bec552e15dbe3706a9f4e88080fce
N/A patches for version.c:
vim-patch:8.1.1801: cannot build without the +eval feature
Problem: Cannot build without the +eval feature.
Solution: Always define funcexe_T.
https://github.com/vim/vim/commit/505e43a20eb25674b18d73971fe3b51dad917f9a
vim-patch:8.1.1818: unused variable
Problem: Unused variable.
Solution: Remove the variable. (Mike Williams)
https://github.com/vim/vim/commit/b4a88a0441a65a0c9411c294825a08ca703f541e
vim-patch:8.2.1464: Vim9: build warning for unused variable
Problem: Vim9: build warning for unused variable.
Solution: Delete the variable declaration.
https://github.com/vim/vim/commit/829ac868b7615d73dbfb536f7fcd44fc7c5b7c1d
vim-patch:8.2.2639: build failure when fsync() is not available
Problem: Build failure when fsync() is not available.
Solution: Add #ifdef.
https://github.com/vim/vim/commit/5ea79a2599d35f75e1ae8a75d2711c754c4cb7c4
vim-patch:8.2.2814: Vim9: unused variable
Problem: Vim9: unused variable. (John Marriott)
Solution: Adjust #ifdef.
https://github.com/vim/vim/commit/b06b50dfa06e1cbefd634e2735e7cd5ddd5b911c
vim-patch:8.2.2947: build failure without the channel feature
Problem: Build failure without the channel feature.
Solution: Add back #ifdef. (John Marriott)
https://github.com/vim/vim/commit/f5bfa8faa7bbe025c10148d37e8b47217a430a3b
vim-patch:8.2.2976: build failure without the +eval feature
Problem: Build failure without the +eval feature.
Solution: Add #ifdefs.
https://github.com/vim/vim/commit/8de901e1f1b051e02a61ae76ad7c925e4c0642e5
vim-patch:8.2.2986: build failure without the profile feature
Problem: Build failure without the profile feature.
Solution: Add #ifdef.
https://github.com/vim/vim/commit/d9f31c13d217b4b97f724774a67a6d1f8640e8ae
vim-patch:8.2.3114: Amiga-like systems: build error using stat()
Problem: Amiga-like systems: build error using stat().
Solution: Only build swapfile_process_running() on systems where it is
actually used. (Ola Söder, closes vim/vim#8519)
https://github.com/vim/vim/commit/599a6e5b3629d943a795cd69e4d3d19886f86405
|
|
|
|
| |
Eliminate `expect_err` in favor of `pcall_err` + `eq` or `matches`.
|
| |
|
| |
|
|
|
|
|
| |
builtin commands are never buffer-local, so we can return empty for that
case.
|
|
|
|
|
|
|
| |
Support more :command attributes:
-bang
-bar
-register
|
|
|
|
|
|
| |
- Always return all keys, with at least NIL value.
- Require `opts` param to be {"builtin":false}
- Validate `opts` param
|
|
|