diff options
-rw-r--r-- | README.md | 1 | ||||
-rw-r--r-- | doc/conform.txt | 1 | ||||
-rw-r--r-- | lua/conform/formatters/hindent.lua | 10 |
3 files changed, 12 insertions, 0 deletions
@@ -235,6 +235,7 @@ You can view this list in vim with `:help conform-formatters` - [golines](https://github.com/segmentio/golines) - A golang formatter that fixes long lines. - [google-java-format](https://github.com/google/google-java-format) - Reformats Java source code according to Google Java Style. - [hcl](https://github.com/hashicorp/hcl) - A formatter for HCL files. +- [hindent](https://github.com/mihaimaruseac/hindent) - Haskell pretty printer. - [htmlbeautifier](https://github.com/threedaymonk/htmlbeautifier) - A normaliser/beautifier for HTML that also understands embedded Ruby. Ideal for tidying up Rails templates. - [indent](https://www.gnu.org/software/indent/) - GNU Indent. - [injected](doc/advanced_topics.md#injected-language-formatting-code-blocks) - Format treesitter injected languages. diff --git a/doc/conform.txt b/doc/conform.txt index e81b2d6..1b763d3 100644 --- a/doc/conform.txt +++ b/doc/conform.txt @@ -280,6 +280,7 @@ FORMATTERS *conform-formatter `google-java-format` - Reformats Java source code according to Google Java Style. `hcl` - A formatter for HCL files. +`hindent` - Haskell pretty printer. `htmlbeautifier` - A normaliser/beautifier for HTML that also understands embedded Ruby. Ideal for tidying up Rails templates. `indent` - GNU Indent. diff --git a/lua/conform/formatters/hindent.lua b/lua/conform/formatters/hindent.lua new file mode 100644 index 0000000..bf2656a --- /dev/null +++ b/lua/conform/formatters/hindent.lua @@ -0,0 +1,10 @@ +---@type conform.FileFormatterConfig +return { + meta = { + url = "https://github.com/mihaimaruseac/hindent", + description = "Haskell pretty printer.", + }, + command = "hindent", + args = { "$FILENAME" }, + stdin = false, +} |