Skip to content

theorderingmachine/proximity.nvim

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

258 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

proximity.nvim

Jump to the nearest upward matching file in one fast motion. Helpful when navigating to known places from the depts of a project. Better when followed with <CTRL-O> for fast returns.

Install this plugin using a plugin manager of choice then setup the plugin:

local proximity = require("proximity")

proximity.setup({
	targets = {
		["<leader>pc"] = { "CHANGELOG.md" },
		["<leader>pr"] = { "README.md" },
	},
})

The above setup options show placeholder values and can be forgone if no other targets are used.

Customizations

Different configurations can find certain files in some other common situations.

Adjacent files

Search for files in related directories on the quest upwards:

proximity.setup({
	targets = {
		["<leader>pm"] = { ".github/MAINTAINERS_GUIDE.md" },
	},
})

Multiple matches

Attempt to find different files using the same motion:

proximity.setup({
	targets = {
		["<leader>pp"] = { "package.json", "pyproject.toml" },
	},
})

About

find the nearest matching file fast

Resources

License

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages

  • Lua 71.0%
  • Nix 26.3%
  • Makefile 2.4%
  • Shell 0.3%