diff --git a/nvim/.config/nvim/README.md b/nvim/.config/nvim/README.md new file mode 100644 index 0000000..67f66ff --- /dev/null +++ b/nvim/.config/nvim/README.md @@ -0,0 +1,73 @@ +# Neovim Notes + +## Splits + +Horizontal split: + +```vim +:sp +``` + +Vertical split: + +```vim +:vs +``` + +Open a file in a horizontal split: + +```vim +:sp path/to/file +``` + +Open a file in a vertical split: + +```vim +:vs path/to/file +``` + +## Window Navigation + +Move between windows with: + +```vim +h/j/k/l +``` + +Cycle through windows: + +```vim +w +``` + +## Terminal + +Open a terminal in the current window: + +```vim +:term +``` + +Open a terminal in a horizontal split: + +```vim +:sp | term +``` + +Open a terminal in a vertical split: + +```vim +:vs | term +``` + +Leave terminal mode and return to normal mode: + +```vim + +``` + +In this config, `` in terminal mode is mapped to the same command: + +```vim + +``` diff --git a/nvim/.config/nvim/lua/romanzy/set.lua b/nvim/.config/nvim/lua/romanzy/set.lua index 3dabc02..bebaa3d 100644 --- a/nvim/.config/nvim/lua/romanzy/set.lua +++ b/nvim/.config/nvim/lua/romanzy/set.lua @@ -34,6 +34,6 @@ vim.opt.listchars = { vim.opt.list = true -- only show the invisible characters inside the code editing buffers -vim.cmd([[autocmd BufWinEnter,TermOpen * if &buftype != '' | setlocal nolist | endif]]) +vim.cmd([[autocmd BufWinEnter * if &buftype != '' | setlocal nolist | endif]]) vim.opt.shell = "bash"