diff options
| author | Kyren223 <contact@kyren.codes> | 2026-05-22 16:13:17 +0300 |
|---|---|---|
| committer | Kyren223 <contact@kyren.codes> | 2026-05-22 16:13:17 +0300 |
| commit | 4453a4406d38697141e7fb9be7abb31860900480 (patch) | |
| tree | 1d6483a5825f4770988d0e35dec0bb2d2f27ff50 /.config/nvim/lua | |
| parent | 4a03fa1b4faee9b3ecced6374e0eca35fd0bdf51 (diff) | |
trying to fix session issues
Diffstat (limited to '.config/nvim/lua')
| -rw-r--r-- | .config/nvim/lua/plugins/auto-session.lua | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/.config/nvim/lua/plugins/auto-session.lua b/.config/nvim/lua/plugins/auto-session.lua index 1bc6c2b..b37629d 100644 --- a/.config/nvim/lua/plugins/auto-session.lua +++ b/.config/nvim/lua/plugins/auto-session.lua @@ -6,5 +6,17 @@ return { session_lens = { load_on_setup = false }, bypass_save_filetypes = { 'snacks_dashboard', 'terminal' }, close_filetypes_on_save = { 'checkhealth', 'build_terminal' }, + pre_save_cmds = { + function() + for _, buf in ipairs(vim.api.nvim_list_bufs()) do + if vim.bo[buf].buftype == 'terminal' then + vim.api.nvim_buf_delete(buf, { force = true }) + end + if vim.bo[buf].filetype == 'build_terminal' then + vim.api.nvim_buf_delete(buf, { force = true }) + end + end + end, + }, }, } |
