diff options
| author | Jan Steinke <jan.steinke@gmail.com> | 2021-08-19 19:11:22 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-08-19 19:11:22 +0200 |
| commit | 615efe666be25117199ec8c9d475b2ef86ac7015 (patch) | |
| tree | 805c2c6d18843632ee7835bc548755aaec3804bd /lua/telescope/command.lua | |
| parent | 161a2e9f61f13c84cc404177a5f5c12e1329666f (diff) | |
Allow range parameters on command parser (#1123)
Diffstat (limited to 'lua/telescope/command.lua')
| -rw-r--r-- | lua/telescope/command.lua | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/lua/telescope/command.lua b/lua/telescope/command.lua index 8d47f5a..a92c29e 100644 --- a/lua/telescope/command.lua +++ b/lua/telescope/command.lua @@ -202,7 +202,7 @@ function command.register_keyword(keyword) split_keywords[keyword] = true end -function command.load_command(cmd, ...) +function command.load_command(start_line, end_line, count, cmd, ...) local args = { ... } if cmd == nil then run_command { cmd = "builtin" } @@ -211,7 +211,11 @@ function command.load_command(cmd, ...) local user_opts = {} user_opts["cmd"] = cmd - user_opts.opts = {} + user_opts.opts = { + start_line = start_line, + end_line = end_line, + count = count, + } for _, arg in ipairs(args) do if arg:find("=", 1) == nil then |
