commit f9559235f3e9fbc7e36b63c2fcbedec91026af7b
parent 7f6d446575e433057ba17da1db7f2347c227ca19
Author: mrgrouse <bdmfegys@duck.com>
Date: Wed, 2 Jul 2025 06:07:00 -0400
move conform and mason back to separate files, lazy was being stupid
Diffstat:
3 files changed, 26 insertions(+), 60 deletions(-)
diff --git a/lua/plugins/conform.lua b/lua/plugins/conform.lua
@@ -0,0 +1,8 @@
+return { "stevearc/conform.nvim",
+ opts = {
+ formatters_by_ft = {
+ lua = { "luaformatter" },
+ c = { "clang-format" },
+ },
+ },
+}
diff --git a/lua/plugins/mason-conform-combined.lua b/lua/plugins/mason-conform-combined.lua
@@ -1,60 +0,0 @@
-return {
- "williamboman/mason.nvim",
- config = function()
- -- import mason
- local mason = require("mason")
-
- -- enable mason and configure icons
- mason.setup({
- ui = {
- icons = {
- package_installed = "✓",
- package_pending = "➜",
- package_uninstalled = "✗",
- },
- },
- })
- end,
- "stevearc/conform.nvim",
- event = { "BufWritePre" },
- cmd = { "ConformInfo" },
- keys = {
- {
- -- Customize or remove this keymap to your liking
- "<leader>f",
- function()
- require("conform").format({ async = true })
- end,
- mode = "",
- desc = "Format buffer",
- },
- },
- -- This will provide type hinting with LuaLS
- ---@module "conform"
- ---@type conform.setupOpts
- opts = {
- -- Define your formatters
- formatters_by_ft = {
- lua = { "stylua" },
- python = { "isort", "black" },
- javascript = { "prettierd", "prettier", stop_after_first = true },
- },
- -- Set default options
- default_format_opts = {
- lsp_format = "fallback",
- },
- -- Set up format-on-save
- format_on_save = { timeout_ms = 500 },
- -- Customize formatters
- formatters = {
- shfmt = {
- prepend_args = { "-i", "2" },
- },
- },
- },
- init = function()
- -- If you want the formatexpr, here is the place to set it
- vim.o.formatexpr = "v:lua.require'conform'.formatexpr()"
- end,
- --"zapling/mason-conform.nvim",
-}
diff --git a/lua/plugins/mason.lua b/lua/plugins/mason.lua
@@ -0,0 +1,18 @@
+return {
+ "williamboman/mason.nvim",
+ config = function()
+ -- import mason
+ local mason = require("mason")
+
+ -- enable mason and configure icons
+ mason.setup({
+ ui = {
+ icons = {
+ package_installed = "✓",
+ package_pending = "➜",
+ package_uninstalled = "✗",
+ },
+ },
+ })
+ end,
+}