Skip to content

Instantly share code, notes, and snippets.

@sardonyx001
Created November 13, 2024 04:56
Show Gist options
  • Select an option

  • Save sardonyx001/e8f4cf48eef9407bfa24d94f80df4ef4 to your computer and use it in GitHub Desktop.

Select an option

Save sardonyx001/e8f4cf48eef9407bfa24d94f80df4ef4 to your computer and use it in GitHub Desktop.
Caddyfile formatter for neovim
return {
{
"stevearc/conform.nvim",
opts = {
formatters_by_ft = {
["_"] = { "caddy_fmt" },
},
formatters = {
caddy_fmt = {
command = "caddy",
args = { "fmt" },
stdin = true,
condition = function(ctx)
return vim.fs.basename(ctx.filename) ~= "Caddyfile"
end,
},
},
},
},
}
@kuvaldini

Copy link
Copy Markdown

also *.caddy

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment