diff options
| author | 2025-04-25 02:51:27 +0300 | |
|---|---|---|
| committer | 2025-04-25 02:51:27 +0300 | |
| commit | 44ffd7e4372862270ba92ca4144d47ecfcd187a3 (patch) | |
| tree | c25f65888b52e522c8ae21c1ebe1b43953ede7e6 /nvim | |
| parent | Поправил zshrc и neovim (diff) | |
| download | dotfiles-44ffd7e4372862270ba92ca4144d47ecfcd187a3.tar.gz dotfiles-44ffd7e4372862270ba92ca4144d47ecfcd187a3.tar.bz2 dotfiles-44ffd7e4372862270ba92ca4144d47ecfcd187a3.tar.xz dotfiles-44ffd7e4372862270ba92ca4144d47ecfcd187a3.zip | |
Поправил zshrc и neovim
Diffstat (limited to '')
| -rw-r--r-- | nvim/lua/autocommands.lua | 10 | ||||
| -rw-r--r-- | nvim/lua/options.lua | 2 |
2 files changed, 12 insertions, 0 deletions
diff --git a/nvim/lua/autocommands.lua b/nvim/lua/autocommands.lua index d9edd27..a0a7e5e 100644 --- a/nvim/lua/autocommands.lua +++ b/nvim/lua/autocommands.lua @@ -115,6 +115,16 @@ vim.api.nvim_create_autocmd("BufLeave", { end, }) +vim.api.nvim_create_autocmd({ "BufReadPost", "BufWinEnter", "WinEnter" }, { + pattern = "*", + callback = function(args) + -- Проверяем, что это не терминальный буфер + if not vim.startswith(vim.api.nvim_buf_get_name(args.buf), "term://") then + vim.cmd("normal zR") -- Развернуть все складки + end + end, +}) + -- vim.api.nvim_create_autocmd("InsertEnter", { -- pattern = "*", -- command = "set norelativenumber", diff --git a/nvim/lua/options.lua b/nvim/lua/options.lua index 359586c..c6e38f4 100644 --- a/nvim/lua/options.lua +++ b/nvim/lua/options.lua @@ -37,6 +37,8 @@ local options = { syntax = "on", foldmethod = "expr", foldexpr = "nvim_treesitter#foldexpr()", + foldlevelstart = 99, + foldenable = true, } vim.opt.shortmess:append("c") |
