chrisgrieser/cmp_yanky

cmp-source for clipboard history from yanky.nvim

Lua

48

51 commits

updated Oct 20, 2025

See the code

README

cmp_yanky

cmp-source for yank history (clipboard history) from yanky.nvim.

demo image showcasing suggestion

Installation

-- lazy.nvim
{
	"hrsh7th/nvim-cmp",
	dependencies = {
		-- ... other cmp plugins
		"chrisgrieser/cmp_yanky",
	}
},
require("cmp").setup {
	sources = {
		{ 
			name = "cmp_yanky",
			option = {
				-- see below
			}
		},
	},
}

Configuration

-- default values
{
	name = "cmp_yanky",
	option = {
		-- only suggest items which match the current filetype
		onlyCurrentFiletype = false,
		-- only suggest items with a minimum length
		minLength = 3,
	},
}

The number of possible items to be suggested depends on the size of the history. You can change the history size with yanky's ring.history_length option.

Credits

In my day job, I am a sociologist studying the social mechanisms underlying the digital economy. For my PhD project, I investigate the governance of the app economy and how software ecosystems manage the tension between innovation and compatibility. If you are interested in this subject, feel free to get in touch.

I also occasionally blog about vim: Nano Tips for Vim

clipboard-history
completion
neovim-plugin
nvim-cmp
nvim-plugin

chrisgrieser/cmp_yanky

cmp-source for clipboard history from yanky.nvim

Lua

48

51 commits

updated Oct 20, 2025

See the code

README

cmp_yanky

cmp-source for yank history (clipboard history) from yanky.nvim.

demo image showcasing suggestion

Installation

-- lazy.nvim
{
	"hrsh7th/nvim-cmp",
	dependencies = {
		-- ... other cmp plugins
		"chrisgrieser/cmp_yanky",
	}
},
require("cmp").setup {
	sources = {
		{ 
			name = "cmp_yanky",
			option = {
				-- see below
			}
		},
	},
}

Configuration

-- default values
{
	name = "cmp_yanky",
	option = {
		-- only suggest items which match the current filetype
		onlyCurrentFiletype = false,
		-- only suggest items with a minimum length
		minLength = 3,
	},
}

The number of possible items to be suggested depends on the size of the history. You can change the history size with yanky's ring.history_length option.

Credits

In my day job, I am a sociologist studying the social mechanisms underlying the digital economy. For my PhD project, I investigate the governance of the app economy and how software ecosystems manage the tension between innovation and compatibility. If you are interested in this subject, feel free to get in touch.

I also occasionally blog about vim: Nano Tips for Vim

clipboard-history
completion
neovim-plugin
nvim-cmp
nvim-plugin