终端安装与配置
安装 neovim
Mac 可以直接使用 Homebrew 直接安装
tmux (option)
tmux config file path ~/.tmux.conf
fix clear
command terminal database is inaccessible
error
add set -g default-terminal "tmux-256color"
into .tmux.conf
tmux config
Neovim 配置
可以基于以下社区方案进行安装配置
LazyVim
LernaVim
AstroVim
下面我将以LazyVim
的安装作为示例
Requirement
Install lazyvim
- start
macos should set
defaults write -g ApplePressAndHoldEnabled --bool false
Config keymap (Option)
According to your own preference.
Shortcut key
- indent
cmd + shift + </>
- move up/down
A-j/k
- search content
leader s g
- search file
leader leader
- hover documentaion
shift k
- variable rename
leader c r
- search in buffer
leader f b
orleader ,
- split window
leader |
- close window
leader w d
- search TODO
leader s t
- search keymaps
leader s k
- switch numberline
leader u l
- replace in file
leader s r
- open git window
leader g
- add stage
leader
- commit
c
- quite lazygit window
q
- add stage
- open terminal
leader f t
- switch filetree
leader e
- toggle format on save
leader u f
- toggle diagnostics
leader u d
Tmux Shortcut
- create new window
C-a c
- close window
C-a x
- switch next window
C-a n
- quite terminal
exit
Quick selection
dependence flash
- remote mode
yr3y
copy 3 linesdr3d
delete 3 lines
- treesitter
yr [char] S