summaryrefslogtreecommitdiff
path: root/lua/telescope/builtin/init.lua
diff options
context:
space:
mode:
authorGutyina Gergő <gutyina.gergo.2@gmail.com>2022-10-24 08:44:13 +0200
committerGitHub <noreply@github.com>2022-10-24 08:44:13 +0200
commit5c7db4055d89f9057d562f4f8b9d03189c9f9786 (patch)
tree0a630d5d92f150c36779fec230f6037d8734f574 /lua/telescope/builtin/init.lua
parent286628d9f2056cc71d3f3871b5ca4f3209de0dbf (diff)
feat: allow table as additional args in live grep and grep string (#2139)
Diffstat (limited to 'lua/telescope/builtin/init.lua')
-rw-r--r--lua/telescope/builtin/init.lua4
1 files changed, 2 insertions, 2 deletions
diff --git a/lua/telescope/builtin/init.lua b/lua/telescope/builtin/init.lua
index 03b3134..5a21994 100644
--- a/lua/telescope/builtin/init.lua
+++ b/lua/telescope/builtin/init.lua
@@ -52,7 +52,7 @@ end
---@field search_dirs table: directory/directories/files to search, mutually exclusive with `grep_open_files`
---@field glob_pattern string|table: argument to be used with `--glob`, e.g. "*.toml", can use the opposite "!*.toml"
---@field type_filter string: argument to be used with `--type`, e.g. "rust", see `rg --type-list`
----@field additional_args function: function(opts) which returns a table of additional arguments to be passed on
+---@field additional_args function|table: additional arguments to be passed on. Can be fn(opts) -> tbl
---@field max_results number: define a upper result value
---@field disable_coordinates boolean: don't show the line & row numbers (default: false)
builtin.live_grep = require_on_exported_call("telescope.builtin.__files").live_grep
@@ -65,7 +65,7 @@ builtin.live_grep = require_on_exported_call("telescope.builtin.__files").live_g
---@field search_dirs table: directory/directories/files to search, mutually exclusive with `grep_open_files`
---@field use_regex boolean: if true, special characters won't be escaped, allows for using regex (default: false)
---@field word_match string: can be set to `-w` to enable exact word matches
----@field additional_args function: function(opts) which returns a table of additional arguments to be passed on
+---@field additional_args function|table: additional arguments to be passed on. Can be fn(opts) -> tbl
---@field disable_coordinates boolean: don't show the line and row numbers (default: false)
---@field only_sort_text boolean: only sort the text, not the file, line or row (default: false)
builtin.grep_string = require_on_exported_call("telescope.builtin.__files").grep_string