1010 - [ Primary stage] ( #primary-stage )
1111 - [ Matching stage] ( #matching-stage )
1212 - [ Features] ( #features )
13+ - [ PICKERS] ( #pickers )
1314 - [ Description] ( #description )
1415 - [ Installation] ( #installation )
1516 - [ Using packer.nvim] ( #using-packernvimhttpsgithubcomwbthomasonpackernvim )
1617 - [ Using lazy.nvim] ( #using-lazynvimhttpsgithubcomfolkelazynvim )
1718 - [ Using vim-plug] ( #using-vim-plughttpsgithubcomjunegunnvim-plug )
1819 - [ Configuration] ( #configuration )
20+ - [ User commands] ( #user-commands )
1921 - [ Quickstart] ( #quickstart )
2022 - [ Static table] ( #static-table )
2123 - [ Callback function] ( #callback-function )
3032 - [ Dynamic streams] ( #dynamic-streams )
3133 - [ Contextual awareness] ( #contextual-awareness )
3234 - [ Interaction] ( #interaction )
33- - [ Interactive and Fuzzy stages] ( #interactive-and-fuzzy -stages )
34- - [ Closing and hiding pickers] ( #closing-and -hiding-pickers )
35+ - [ Interactive & Matching stages] ( #interactive--matching -stages )
36+ - [ Closing & hiding pickers] ( #closing--hiding-pickers )
3537 - [ Dynamic context evaluation] ( #dynamic-context-evaluation )
36- - [ Picker actions & interaction] ( #picker- actions--interaction )
38+ - [ Actions & interaction] ( #actions--interaction )
3739 - [ Picker Options] ( #picker-options )
3840 - [ Core options] ( #core-options )
3941 - [ Advanced options] ( #advanced-options )
4042 - [ Option details] ( #option-details )
4143 - [ Core options] ( #core-options-1 )
4244 - [ Advanced options] ( #advanced-options-1 )
43- - [ In-depth look ] ( #in-depth-look )
45+ - [ In-depth description ] ( #in-depth-description )
4446 - [ Actions] ( #actions )
4547 - [ Previewers] ( #previewers )
4648 - [ Decorators] ( #decorators )
49+ - [ Highlighters] ( #highlighters )
4750 - [ Converters] ( #converters )
4851 - [ Examples] ( #examples )
4952 - [ Interactive grep] ( #interactive-grep )
@@ -177,6 +180,10 @@ require("fuzzy").setup({
177180 general = {
178181 -- override the built-in `vim.ui.select` with fuzzymatch
179182 override_select = true ,
183+ user_command = {
184+ enabled = true ,
185+ name = " Fzm" ,
186+ },
180187 }
181188
182189 -- Scheduler controls the async budget for cooperative tasks
@@ -203,6 +210,8 @@ require("fuzzy").setup({
203210Configuration details:
204211
205212- ` general.override_select ` : Replaces ` vim.ui.select ` with the built-in picker-based implementation.
213+ - ` general.user_command.enabled ` : Registers the user command that opens pickers by name.
214+ - ` general.user_command.name ` : Command name used for pickers (default: ` Fzm ` ).
206215- ` scheduler.async_budget ` : Time budget in microseconds for cooperative async tasks.
207216- ` pool.max_idle ` : Maximum idle time in milliseconds before a pooled table is discarded.
208217- ` pool.prune_interval ` : Interval in milliseconds for pool cleanup.
@@ -226,6 +235,30 @@ when the picker is re-opened the context will be re-evaluated and if it has chan
226235` TDDR; ` To start using the picker simply require the picker and select modules those are going to be enough for you to create pretty much any
227236type of picker you can imagine. Lets see a few examples
228237
238+ ### User command
239+
240+ The ` :Fzm ` command opens any picker by name, with optional ` key=value ` arguments. You can change the
241+ command name with ` general.user_command.name ` .
242+
243+ ``` vim
244+ :Fzm files
245+ :Fzm grep cwd=/path/to/project
246+ :Fzm grep args=--hidden,--iglob=*.lua prompt_query="init.lua"
247+ :Fzm manpages args=-k,. preview=false
248+ ```
249+
250+ - ` cwd ` : working directory (string)
251+ - ` args ` : comma-separated list (quoted strings supported)
252+ - ` env ` : comma-separated list (quoted strings supported)
253+ - ` preview ` : ` true|false `
254+ - ` icons ` : ` true|false `
255+ - ` watch ` : ` true|false `
256+ - ` prompt_query ` : initial prompt string (quote if it contains spaces)
257+ - ` prompt_debounce ` , ` match_limit ` , ` match_timer ` , ` match_step ` , ` stream_step ` , ` stream_debounce ` : numbers
258+ - ` stream_type ` : ` lines|bytes `
259+ - ` window_size ` : number (0-1)
260+ - ` interactive ` : ` true|false `
261+
229262### Static table
230263
231264Use a static table when you already have all entries in memory. This produces a non-interactive picker: the list is shown as-is and no
0 commit comments