Neovim plugin improving access to clipboard history (mirror)
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

fix/feat(fixed popup going below bottom of screen, added makefile for styling and linting)

+12 -3
+9
Makefile
··· 1 + fmt: 2 + echo "Formatting lua/yankbank..." 3 + stylua lua/ --config-path=.stylua.toml 4 + 5 + lint: 6 + echo "Linting lua/yankbank..." 7 + luacheck lua/ --globals vim 8 + 9 + pr-ready: fmt lint
+1 -1
lua/yankbank/clipboard.lua
··· 24 24 callback = function() 25 25 -- TODO: this function can be expanded to incorporate other registers 26 26 -- - use vim.v.event.regname and an allowlist 27 + -- local reg_type = vim.v.event.operator 27 28 -- if reg_type == "y" or reg_type == "d" then 28 29 -- local yanked_text = vim.fn.getreg('"') 29 30 30 31 -- get register information 31 - local reg_type = vim.v.event.operator 32 32 local rn = vim.v.event.regname 33 33 34 34 -- check changes wwere made to default register
+2 -2
lua/yankbank/menu.lua
··· 53 53 -- FIX: long enough entries will cause window to go below end of screen 54 54 -- FIX: wrapping long lines will cause entries below to not show in menu (requires scrolling to see) 55 55 local width = 56 - math.min(max_width + 4, vim.api.nvim_get_option_value("columns", {})) 56 + math.min(max_width, vim.api.nvim_get_option_value("columns", {}) - 4) 57 57 local height = math.min( 58 58 display_lines and #display_lines or 1, 59 - vim.api.nvim_get_option_value("lines", {}) 59 + vim.api.nvim_get_option_value("lines", {}) - 10 60 60 ) 61 61 62 62 -- open window