Fix #481
This commit is contained in:
@@ -77,8 +77,10 @@ end
|
|||||||
---@return string
|
---@return string
|
||||||
keymap.autoindent = function()
|
keymap.autoindent = function()
|
||||||
local keys = {}
|
local keys = {}
|
||||||
|
table.insert(keys, keymap.t('<Cmd>setlocal cindent<CR>'))
|
||||||
table.insert(keys, keymap.t('<Cmd>setlocal indentkeys+=!^F<CR>'))
|
table.insert(keys, keymap.t('<Cmd>setlocal indentkeys+=!^F<CR>'))
|
||||||
table.insert(keys, keymap.t('<C-f>'))
|
table.insert(keys, keymap.t('<C-f>'))
|
||||||
|
table.insert(keys, keymap.t('<Cmd>setlocal %scindent<CR>'):format(vim.bo.cindent and '' or 'no'))
|
||||||
table.insert(keys, keymap.t('<Cmd>setlocal indentkeys=%s<CR>'):format(vim.bo.indentkeys:gsub( '|', '\\|')))
|
table.insert(keys, keymap.t('<Cmd>setlocal indentkeys=%s<CR>'):format(vim.bo.indentkeys:gsub( '|', '\\|')))
|
||||||
return table.concat(keys, '')
|
return table.concat(keys, '')
|
||||||
end
|
end
|
||||||
|
|||||||
Reference in New Issue
Block a user