Caddy(8)
π NAME π
caddy-fmt β bestie, it formats your Caddyfile β¨
π¦ SYNOPSIS π¦
caddy fmt [--overwrite] [--diff] [] [flags]
πΈ DESCRIPTION πΈ
Okay so caddy fmt takes your Caddyfile and gives it a whole glow-up: it adds proper indentation and spaces so actual humans can read it without squinting π. The result gets printed to stdout, that's the default vibe.
If you pass --overwrite, the output is written straight to the config file itself instead of being printed. No dying of suspense on stdout, it just goes in π.
If you pass --diff, the output gets compared against the input, and lines get prefixed with - and + wherever they differ. Quick heads up though: unchanged lines get prefixed with two spaces for alignment, and this is not a valid patch format β so don't go feeding it to patch, ok? π
And if you want stdin instead of a regular file (iconic move honestly), just use - as the path. But heads up: when you're reading from stdin, the --overwrite flag has no effect β the result is always printed to stdout. That's just the rules π.
π OPTIONS π
-c,--config=""β Configuration file-d,--diff[=false]β Print the differences between the input file and the formatted output-h,--help[=false]β help for fmt-w,--overwrite[=false]β Overwrite the input file with the results
π SEE ALSO π
β HISTORY β
1-Jan-0001 Auto generated by spf13/cobra
π«Ά and that's the whole page bestie, no cap. This was auto generated by spf13/cobra, dated Jan 0001, and it lives in the Caddy(8) manual β go format something pretty now πβ¨
π¦ where this page comes from
- ubuntu stonking: caddy 2.11.4-1 Β· Apache-2.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms