aboutsummaryrefslogtreecommitdiffstats
path: root/lua
diff options
context:
space:
mode:
Diffstat (limited to 'lua')
-rw-r--r--lua/conform/init.lua8
-rw-r--r--lua/conform/types.lua2
2 files changed, 9 insertions, 1 deletions
diff --git a/lua/conform/init.lua b/lua/conform/init.lua
index 208edc7..087445b 100644
--- a/lua/conform/init.lua
+++ b/lua/conform/init.lua
@@ -209,6 +209,10 @@ M.list_formatters_for_buffer = function(bufnr)
local function dedupe_formatters(names, collect)
for _, name in ipairs(names) do
if type(name) == "table" then
+ vim.notify_once(
+ "deprecated[conform]: The nested {} syntax to run the first formatter has been replaced by the stop_after_first option. See :help conform.format. Support for the old syntax will be dropped on 2025-01-01.",
+ vim.log.levels.WARN
+ )
local alternation = {}
dedupe_formatters(name, alternation)
if not vim.tbl_isempty(alternation) then
@@ -322,6 +326,10 @@ M.resolve_formatters = function(names, bufnr, warn_on_missing, stop_after_first)
local info = M.get_formatter_info(name, bufnr)
add_info(info, warn_on_missing)
else
+ vim.notify_once(
+ "deprecated[conform]: The nested {} syntax to run the first formatter has been replaced by the stop_after_first option. See :help conform.format. Support for the old syntax will be dropped on 2025-01-01.",
+ vim.log.levels.WARN
+ )
-- If this is an alternation, take the first one that's available
for i, v in ipairs(name) do
local info = M.get_formatter_info(v, bufnr)
diff --git a/lua/conform/types.lua b/lua/conform/types.lua
index 9b775a9..007e84a 100644
--- a/lua/conform/types.lua
+++ b/lua/conform/types.lua
@@ -62,7 +62,7 @@
---This list of formatters to run for a filetype, an any associated format options.
---@class conform.FiletypeFormatterInternal : conform.DefaultFormatOpts
----@field [integer] string|string[]
+---@field [integer] string
---@alias conform.LspFormatOpts
---| '"never"' # never use the LSP for formatting (default)