aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--README.md3
-rw-r--r--doc/conform.txt4
-rw-r--r--lua/conform/formatters/fourmolu.lua2
-rw-r--r--lua/conform/formatters/ormolu.lua10
4 files changed, 16 insertions, 3 deletions
diff --git a/README.md b/README.md
index 2ff572b..ac8d2f0 100644
--- a/README.md
+++ b/README.md
@@ -219,7 +219,8 @@ You can view this list in vim with `:help conform-formatters`
- [fish_indent](https://fishshell.com/docs/current/cmds/fish_indent.html) - Indent or otherwise prettify a piece of fish code.
- [fixjson](https://github.com/rhysd/fixjson) - JSON Fixer for Humans using (relaxed) JSON5.
- [fnlfmt](https://git.sr.ht/~technomancy/fnlfmt) - A formatter for Fennel code.
-- [fourmolu](https://hackage.haskell.org/package/fourmolu) - Fourmolu is a formatter for Haskell source code.
+- [ormolu](https://hackage.haskell.org/package/ormolu) - A formatter for Haskell source code.
+- [fourmolu](https://hackage.haskell.org/package/fourmolu) - A fourk of ormolu that uses four space indentation and allows arbitrary configuration.
- [gci](https://github.com/daixiang0/gci) - GCI, a tool that controls Go package import order and makes it always deterministic.
- [gdformat](https://github.com/Scony/godot-gdscript-toolkit) - A formatter for Godot's gdscript.
- [gersemi](https://github.com/BlankSpruce/gersemi) - A formatter to make your CMake code the real treasure.
diff --git a/doc/conform.txt b/doc/conform.txt
index 977a0f0..2a406d9 100644
--- a/doc/conform.txt
+++ b/doc/conform.txt
@@ -233,7 +233,9 @@ FORMATTERS *conform-formatter
`fish_indent` - Indent or otherwise prettify a piece of fish code.
`fixjson` - JSON Fixer for Humans using (relaxed) JSON5.
`fnlfmt` - A formatter for Fennel code.
-`fourmolu` - Fourmolu is a formatter for Haskell source code.
+`ormolu` - A formatter for Haskell source code.
+`fourmolu` - A fourk of ormolu that uses four space indentation and allows
+ arbitrary configuration
`gci` - GCI, a tool that controls Go package import order and makes it always
deterministic.
`gdformat` - A formatter for Godot's gdscript.
diff --git a/lua/conform/formatters/fourmolu.lua b/lua/conform/formatters/fourmolu.lua
index 9c64999..4e1db8e 100644
--- a/lua/conform/formatters/fourmolu.lua
+++ b/lua/conform/formatters/fourmolu.lua
@@ -2,7 +2,7 @@
return {
meta = {
url = "https://hackage.haskell.org/package/fourmolu",
- description = "Fourmolu is a formatter for Haskell source code.",
+ description = "A fork of ormolu that uses four space indentation and allows arbitrary configuration.",
},
command = "fourmolu",
args = { "--stdin-input-file", "$FILENAME" },
diff --git a/lua/conform/formatters/ormolu.lua b/lua/conform/formatters/ormolu.lua
new file mode 100644
index 0000000..4c36929
--- /dev/null
+++ b/lua/conform/formatters/ormolu.lua
@@ -0,0 +1,10 @@
+---@type conform.FileFormatterConfig
+return {
+ meta = {
+ url = "https://hackage.haskell.org/package/ormolu",
+ description = "A formatter for Haskell source code.",
+ },
+ command = "ormolu",
+ args = { "--stdin-input-file", "$FILENAME" },
+ stdin = true,
+}