···11-*yankbank-nvim.txt* For Neovim >= 0.7.0 Last change: 2024 June 11
11+*yankbank-nvim.txt* For Neovim >= 0.7.0 Last change: 2024 June 12
2233==============================================================================
44Table of Contents *yankbank-nvim-table-of-contents*
···2323YankBank stores the N recent yanks into the unnamed register (“), then
2424populates a popup window with these recent yanks, allowing for quick access to
2525recent yank history. Upon opening the popup menu, the current contents of the
2626-unnamedplus (+) register are also added to the menu (if they are different than
2626+unnamedplus (+) register are also added to the menu (if they are different from
2727the current contents of the unnamed register).
28282929Choosing an entry from the menu (by hitting enter) will paste it into the
···7373| | keymaps.navigation_prev | string | `"k"` | | keymaps.paste | string |
7474`"<CR>"` | | keymaps.yank | string | `"yy"` | | keymaps.close | table of
7575strings | `{ "<Esc>", "<C-c>", "q" }` | | num_behavior | string defining jump
7676-behavior "prefix" or "jump" | `"prefix"` | | registers | table container for
7777-register overrides | `{ }` | | registers.yank_register | default register to
7878-yank from popup to | `"+"` |
7676+behavior "prefix" or "jump" | `"prefix"` | | focus_gain_poll | boolean | `nil`
7777+| | registers | table container for register overrides | `{ }` | |
7878+registers.yank_register | default register to yank from popup to | `"+"` |
79798080-If no separator is desired, pass in an empty string for sep:
8080+8181+EXAMPLE CONFIGURATION
81828283>lua
8384 config = function()
8485 require('yankbank').setup({
8585- max_entries = 12,
8686+ max_entries = 9,
8687 sep = "",
8888+ num_behavior = "prefix",
8989+ focus_gain_poll = true,
8790 keymaps = {
8891 navigation_next = "j",
8992 navigation_prev = "k",
9093 },
9191- num_behavior = "prefix",
9494+ registers = {
9595+ yank_register = "+",
9696+ },
9297 })
9398 end,
9499<
100100+101101+If no separator is desired, pass in an empty string for `sep`
9510296103The 'num_behavior' option defines in-popup navigation behavior when hitting
97104number keys. - `num_behavior = "prefix"` works similar to traditional vim
···100107entry 3) - Note: If 'max_entries' is a two-digit number, there will be a delay
101108upon pressing numbers that prefix a valid entry.
102109110110+The 'focus_gain_poll' option allows for enabling an additional autocommand that
111111+watches for focus gains (refocusing Neovim window), and checks for changes in
112112+the unnamedplus ('+') register, adding to yankbank when new contents are found.
113113+This allows for automatically adding text copied from other sources (like a
114114+browser) to the yankbank without the bank opening trigger. Off by default, but
115115+I highly recommend enabling it (`focus_gain_poll = true`)
116116+103117104118USAGE *yankbank-nvim-yankbank-usage*
105119···119133POTENTIAL IMPROVEMENTS *yankbank-nvim-yankbank-potential-improvements*
120134121135- Persistence between sessions (through either sqlite database or just a file)
122122-- Polling on unnamedplus register to populate bank in more intuitive manner (could be enabled as option)
123136- nvim-cmp integration
124137- fzf integration
125125-- Setup options configuring which registers are included
126138127139128140ALTERNATIVES *yankbank-nvim-yankbank-alternatives*
···133145==============================================================================
1341462. Links *yankbank-nvim-links*
135147136136-1. *YankBank popup window*: assets/screenshot-1.png
137137-2. *YankBank popup window zoomed*: assets/screenshot-2.png
148148+1. *YankBank popup window zoomed*: assets/screenshot-2.png
138149139150Generated by panvimdoc <https://github.com/kdheepak/panvimdoc>
140151