Neovim plugin improving access to clipboard history (mirror)

doc: improved readme

+17 -5
+16 -4
README.md
··· 1 1 # YankBank 2 - A Neovim plugin for keeping track of more recent yanks and deletions and exposing them in a quick to access menu. 2 + A Neovim plugin for keeping track of more recent yanks and deletions and exposing them in a quick access menu. 3 3 4 4 ## What it Does 5 - <!-- TODO: screenshots --> 6 - <!-- TODO: talk about how the menu populates--> 7 - TODO: 5 + YankBank stores the N recent yanks into the unnamed register ("), then populates a popup window with these recent yanks, allowing for quick access to recent yank history. 6 + Upon opening the popup menu, the current contents of the unnamedplus (+) register are also added to the menu (if they are different than the current contents of the unnamed register). 8 7 8 + Choosing an entry from the menu (by hitting enter) will paste it into the currently open buffer at the cursor position. 9 + 10 + Popup window: 11 + ![YankBank popup window](assets/screenshot-1.png) 12 + 13 + The menu is specific to the current session, and will only contain the contents of the current unnamedplus register upon opening in a completely new session. 14 + It will be populated further for each yank or deletion in that session. 9 15 10 16 ## Installation and Setup 11 17 ··· 39 45 vim.keymap.set("n", "<leader>y", ":YankBank<CR>", { noremap = true }) 40 46 ``` 41 47 48 + ## Potential Improvements 49 + - Disallow duplicate entries 50 + - Keybind for yanking from menu instead of pasting 51 + - Expose popup keybind behavior through setup options 52 + - Access to other registers (number/letter registers?) 53 +
assets/screenshot-1.png

This is a binary file and will not be displayed.

+1 -1
lua/yankbank/menu.lua
··· 55 55 width = width, 56 56 height = height, 57 57 col = math.floor((vim.api.nvim_get_option("columns") - width) / 2 - 1), 58 - row = math.floor((vim.api.nvim_get_option("lines") - height) / 2) - 1, 58 + row = math.floor((vim.api.nvim_get_option("lines") - height) / 2 - 1), 59 59 border = "rounded", 60 60 style = "minimal", 61 61 })