fix(nvim): only apply lists when in a list for autolist

This commit is contained in:
Price Hiller 2023-08-20 03:37:43 -05:00
parent 1790d642e9
commit b340a5ca86
Signed by: Price
SSH Key Fingerprint: SHA256:Y4S9ZzYphRn1W1kbJerJFO6GGsfu9O70VaBSxJO7dF8

View File

@ -9,17 +9,20 @@ return {
"plaintex", "plaintex",
"norg", "norg",
"yaml", "yaml",
"yaml.ansible" "yaml.ansible",
}, },
config = function() config = function()
require("autolist").setup({ require("autolist").setup({
colon = {
indent_raw = false,
},
lists = { lists = {
yaml = { yaml = {
"[-]", "[-]",
}, },
["yaml.ansible"] = { ["yaml.ansible"] = {
"[-]" "[-]",
} },
}, },
}) })
local autolist_group = vim.api.nvim_create_augroup("Autolist", {}) local autolist_group = vim.api.nvim_create_augroup("Autolist", {})
@ -32,7 +35,7 @@ return {
"plaintex", "plaintex",
"norg", "norg",
"yaml", "yaml",
"yaml.ansible" "yaml.ansible",
}, },
callback = function() callback = function()
if pcall(require, "autolist") then if pcall(require, "autolist") then