diff options
author | bfredl <bjorn.linse@gmail.com> | 2022-09-30 09:43:18 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-09-30 09:43:18 +0200 |
commit | 9cf252e12153aa8bf657631a8ed2b83888948fb0 (patch) | |
tree | 8342c6f8f9b3d94f335edd52e88d1adc0f7c4d9b /runtime | |
parent | 33dd917d7fdc40483b3d18d0c7bcf5994b26fe86 (diff) | |
parent | e46eef75ac2c3336928269e28a1fa138f7327207 (diff) | |
download | rneovim-9cf252e12153aa8bf657631a8ed2b83888948fb0.tar.gz rneovim-9cf252e12153aa8bf657631a8ed2b83888948fb0.tar.bz2 rneovim-9cf252e12153aa8bf657631a8ed2b83888948fb0.zip |
Merge pull request #20387 from famiu/feat/nvim_cmd/buffer-args
feat(nvim_cmd)!: allow using first argument as count
Diffstat (limited to 'runtime')
-rw-r--r-- | runtime/doc/api.txt | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/runtime/doc/api.txt b/runtime/doc/api.txt index 59d1d36be9..9515dea9a2 100644 --- a/runtime/doc/api.txt +++ b/runtime/doc/api.txt @@ -1697,7 +1697,13 @@ nvim_cmd({*cmd}, {*opts}) *nvim_cmd()* of a String. This allows for easier construction and manipulation of an Ex command. This also allows for things such as having spaces inside a command argument, expanding filenames in a command that otherwise doesn't - expand filenames, etc. + expand filenames, etc. Command arguments may also be Number, Boolean or + String. + + The first argument may also be used instead of count for commands that + support it in order to make their usage simpler with |vim.cmd()|. For + example, instead of `vim.cmd.bdelete{ count = 2 }`, you may do + `vim.cmd.bdelete(2)`. On execution error: fails with VimL error, updates v:errmsg. |