Overseer
parent
a91efd762c
commit
c55ae33c51
@ -0,0 +1,6 @@
|
|||||||
|
return {
|
||||||
|
'stevearc/overseer.nvim',
|
||||||
|
opts = {
|
||||||
|
templates = { "builtin", "user.run_script" },
|
||||||
|
},
|
||||||
|
}
|
@ -0,0 +1,22 @@
|
|||||||
|
-- /home/stevearc/.config/nvim/lua/overseer/template/user/run_script.lua
|
||||||
|
return {
|
||||||
|
name = "run script",
|
||||||
|
builder = function()
|
||||||
|
local file = vim.fn.expand("%:p")
|
||||||
|
local cmd = { file }
|
||||||
|
if vim.bo.filetype == "go" then
|
||||||
|
cmd = { "go", "run", file }
|
||||||
|
end
|
||||||
|
return {
|
||||||
|
cmd = cmd,
|
||||||
|
components = {
|
||||||
|
{ "on_output_quickfix", set_diagnostics = true },
|
||||||
|
"on_result_diagnostics",
|
||||||
|
"default",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
end,
|
||||||
|
condition = {
|
||||||
|
filetype = { "sh", "python", "go" },
|
||||||
|
},
|
||||||
|
}
|
Loading…
Reference in New Issue