Skip to content

Commit d374758

Browse files
committed
fix(auto-save-nvim): auto saving in fyler
1 parent eb2204e commit d374758

File tree

1 file changed

+14
-1
lines changed
  • lua/astrocommunity/editing-support/auto-save-nvim

1 file changed

+14
-1
lines changed

lua/astrocommunity/editing-support/auto-save-nvim/init.lua

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,14 @@
1+
local excluded_filetypes = {
2+
"oil",
3+
"Fyler",
4+
}
5+
6+
local function save_condition(buf)
7+
if vim.tbl_contains(excluded_filetypes, vim.fn.getbufvar(buf, "&filetype")) then return false end
8+
9+
return true
10+
end
11+
112
return {
213
"okuuva/auto-save.nvim",
314
event = { "User AstroFile", "InsertEnter" },
@@ -46,5 +57,7 @@ return {
4657
},
4758
},
4859
},
49-
opts = {},
60+
opts = {
61+
condition = save_condition,
62+
},
5063
}

0 commit comments

Comments
 (0)