From 9443e1ebe18d6e270ed931d5e2e1daa97af524be Mon Sep 17 00:00:00 2001 From: mawkler Date: Tue, 3 Sep 2024 19:28:16 +0000 Subject: [PATCH] docs: auto generate vimdoc --- doc/refjump.txt | 95 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 95 insertions(+) create mode 100644 doc/refjump.txt diff --git a/doc/refjump.txt b/doc/refjump.txt new file mode 100644 index 0000000..a575ac9 --- /dev/null +++ b/doc/refjump.txt @@ -0,0 +1,95 @@ +*refjump.txt* For NVIM v0.8.0 Last change: 2024 September 03 + +============================================================================== +Table of Contents *refjump-table-of-contents* + +1. Refjump |refjump-refjump| + - Installation |refjump-refjump-installation| + - Usage |refjump-refjump-usage| + - Configuration |refjump-refjump-configuration| + - Integrations |refjump-refjump-integrations| + +============================================================================== +1. Refjump *refjump-refjump* + +Jump to next/previous LSP reference in the current buffer for the item under +the cursor with `]r`/`[r`. + +If you have demicolon.nvim +installed you can also repeat jumps with `;`/`,`. See the +|refjump-demicolon-section| for more information. + + +https://github.com/user-attachments/assets/7109c1bc-1664-46eb-b16a-fa65c4f05f74 + + +INSTALLATION *refjump-refjump-installation* + +With lazy.nvim : + +>lua + { + 'mawkler/refjump.nvim', + -- keys = { ']r', '[r' }, -- Uncomment to lazy load + opts = {} + } +< + + +USAGE *refjump-refjump-usage* + +- Press `]r` or `[r` to jump to the next/previous reference for the item under the cursor. +- Press `;`/`,` to keep jumping forward/backward between those references (requires demicolon.nvim ) + +You can also prefix any jump with a count. For example, you can do `3]r` to +jump to the third next reference. This also works for `;`/`,`. + + +CONFIGURATION *refjump-refjump-configuration* + +The following is the default configuration: + +>lua + opts = { + keymaps = { + enable = true, + next = ']r', -- Keymap to jump to next LSP reference + prev = '[r', -- Keymap to jump to previous LSP reference + }, + highlights = { + enable = true, -- Highlight the LSP references on jump + auto_clear = true, -- Automatically clear highlights when cursor moves + }, + integrations = { + demicolon = { + enable = true, -- Make `]r`/`[r` repeatable with `;`/`,` using demicolon.nvim + }, + }, + verbose = true, -- Print message if no reference is found + } +< + + +HIGHLIGHTS ~ + +Refjump highlights the references by default. It uses the highlight group +`RefjumpReferences`. To change the highlight, see `:help nvim_set_hl()`. + + +INTEGRATIONS *refjump-refjump-integrations* + + +DEMICOLON ~ + +This plugin integrates with demicolon.nvim +. Demicolon lets you repeat +`]r`/`[r` jumps with `;`/`,` (you can also still repeat `t`/`f`/`T`/`F` like +you would expect). Refjump will cache the list of LSP references which gives +you super responsive jump repetitions. + +This integration is automatically set up if demicolon.nvim is detected and the +option `integrations.demicolon.enable` is `true`. + +Generated by panvimdoc + +vim:tw=78:ts=8:noet:ft=help:norl: