Simple telescope extension to run GNU Make targets in Neovim.
Only tested on GNU/Linux.
Requires the akinsho/nvim-toggleterm.lua plugin for now.
For LunarVim, in your config.lua:
lvim.plugins = {
{
"ptethng/telescope-makefile",
},
}
require'telescope'.load_extension('make')
:Telescope make
Default:
require'telescope-makefile'.setup{
-- The path where to search the makefile in the priority order
makefile_priority = { '.', 'build/' },
toggle_term = {
cmd = 'make',
direction = 'float',
close_on_exit = false,
},
}
Example keybinding in LunarVim and which-key:
lvim.builtin.which_key.mappings.M = {
"<cmd>Telescope make<cr>",
"Make Targets",
}