Skip to content

Commit

Permalink
fix(docs): more duplicate tags in OPTIONS.md (#1165)
Browse files Browse the repository at this point in the history
  • Loading branch information
ibhagwan committed Apr 30, 2024
1 parent 4694946 commit a4bce02
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 32 deletions.
16 changes: 4 additions & 12 deletions OPTIONS.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ add to this document.**
- [Pickers](#pickers)
+ [Buffers and Files](#buffers-and-files)
+ [Search](#search)
+ [Tags](#tags)
+ [CTags](#ctags)
+ [Git](#git)
+ [LSP | Diagnostics](#lspdiagnostics)
+ [Misc](#misc)
Expand Down Expand Up @@ -682,11 +682,7 @@ Alias to `:FzfLua grep resume=true`

#### grep_cword

Grep word under cursor

#### grep_cWORD

Grep WORD under cursor
Grep word/WORD under cursor

#### grep_visual

Expand All @@ -702,7 +698,7 @@ Grep on current buffer only

---

### Tags
### CTags

#### tags

Expand All @@ -722,11 +718,7 @@ Search current buffer ctags

#### tags_grep_cword

Tags-Grep word under cursor

#### tags_grep_cWORD

Tags-Grep WORD under cursor
Tags-Grep word/WORD under cursor

#### tags_grep_visual

Expand Down
26 changes: 7 additions & 19 deletions doc/fzf-lua-opts.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Global Options ................................. |fzf-lua-opts-global-options|
Pickers ............................................... |fzf-lua-opts-pickers|
Buffers and Files ........................... |fzf-lua-opts-buffers-and-files|
Search ................................................. |fzf-lua-opts-search|
Tags ..................................................... |fzf-lua-opts-tags|
CTags ................................................... |fzf-lua-opts-ctags|
Git ....................................................... |fzf-lua-opts-git|
LSP/Diagnostics ............................... |fzf-lua-opts-lsp/diagnostics|
Misc ..................................................... |fzf-lua-opts-misc|
Expand All @@ -35,9 +35,9 @@ FZF-LUA COMMANDS AND OPTIONS *fzf-lua-opts-fzf-lua-commands-and-options*
- Setup Options <#setup-options>
- Global Options <#global-options>
- Pickers <#pickers> + Buffers and Files <#buffers-and-files> + Search
<#search> + Tags <#tags> + Git <#git> + LSP | Diagnostics <#lspdiagnostics>
+ Misc <#misc> + Neovim API <#neovim-api> + `nvim-dap` <#nvim-dap> + `tmux`
<#tmux> + Completion Functions <#completion-functions>
<#search> + CTags <#ctags> + Git <#git> + LSP | Diagnostics
<#lspdiagnostics> + Misc <#misc> + Neovim API <#neovim-api> + `nvim-dap`
<#nvim-dap> + `tmux` <#tmux> + Completion Functions <#completion-functions>

------------------------------------------------------------------------------
GENERAL USAGE *fzf-lua-opts-general-usage*
Expand Down Expand Up @@ -934,13 +934,7 @@ Alias to `:FzfLua grep resume=true`

grep_cword *fzf-lua-opts-grep_cword*

Grep word under cursor



grep_cWORD *fzf-lua-opts-grep_cword*

Grep WORD under cursor
Grep word/WORD under cursor



Expand All @@ -962,7 +956,7 @@ lgrep_curbuf *fzf-lua-opts-lgrep_curbuf*



TAGS *fzf-lua-opts-tags*
CTAGS *fzf-lua-opts-ctags*



Expand Down Expand Up @@ -992,13 +986,7 @@ tags_live_grep *fzf-lua-opts-tags_live_grep*

tags_grep_cword *fzf-lua-opts-tags_grep_cword*

Tags-Grep word under cursor



tags_grep_cWORD *fzf-lua-opts-tags_grep_cword*

Tags-Grep WORD under cursor
Tags-Grep word/WORD under cursor



Expand Down
3 changes: 2 additions & 1 deletion lua/fzf-lua/cmp_src.lua
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,8 @@ end
function Src:_get_documentation(completion_item)
local options_md = require("fzf-lua.cmd").options_md()
if not options_md or vim.tbl_isempty(options_md) then return end
local markdown = options_md[completion_item.label]
-- Test for `label:lower()` to match both `grep_c{word|WORD}`
local markdown = options_md[completion_item.label] or options_md[completion_item.label:lower()]
if not markdown and completion_item.data then
-- didn't find matching the label directly, search globals
-- this will match "winopts.row" as "globals.winopts.row"
Expand Down

0 comments on commit a4bce02

Please sign in to comment.