diff options
| author | coast <coasteen@proton.me> | 2026-10-13 05:03:11 +0330 |
|---|---|---|
| committer | coast <coasteen@proton.me> | 2026-10-13 05:03:11 +0330 |
| commit | 8c5c2d270fd0f3bbc276e3b1cc28fc1dfae3fa59 (patch) | |
| tree | a18e4d6016c4df3ca97e017b9f9d351398e950da /nvim/lua/plugins/conform | |
| download | coast-newdot-8c5c2d270fd0f3bbc276e3b1cc28fc1dfae3fa59.tar.gz coast-newdot-8c5c2d270fd0f3bbc276e3b1cc28fc1dfae3fa59.tar.bz2 coast-newdot-8c5c2d270fd0f3bbc276e3b1cc28fc1dfae3fa59.tar.xz coast-newdot-8c5c2d270fd0f3bbc276e3b1cc28fc1dfae3fa59.tar.zst | |
init
Diffstat (limited to 'nvim/lua/plugins/conform')
| -rw-r--r-- | nvim/lua/plugins/conform/init.lua | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/nvim/lua/plugins/conform/init.lua b/nvim/lua/plugins/conform/init.lua new file mode 100644 index 0000000..374ed55 --- /dev/null +++ b/nvim/lua/plugins/conform/init.lua @@ -0,0 +1,17 @@ +require("conform").setup({ + formatters_by_ft = { + haskell = { "ormolu" }, + }, + formatters = { + ormolu = { + command = "ormolu", + args = { "--stdin-input-file", "$FILENAME" }, + stdin = true, + }, + }, + format_on_save = { timeout_ms = 2000, lsp_format = "never" }, +}) + +vim.keymap.set({ "n", "v" }, "<leader>f", function() + require("conform").format({ async = true, lsp_format = "never" }) +end) |
