summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorxs <xs@xs.local>2026-11-09 02:27:30 +0800
committerxs <xs@xs.local>2026-11-09 02:27:30 +0800
commitc647d422cd001c7845bcec05c06fdbd54b3efec4 (patch)
treef25ff3882b960bf9b88ea2c1338cf5ab6a726419
parentbe18563c9a1c1fcd80eef702883a8443d8bac42e (diff)
tmux: history-limit 10000; vimrc: gr references with ]r/[r, ]e/[e next/prev error, \l/\L list errors (file/project), drop gi and vim-matchup
-rw-r--r--core/tmux.conf3
-rw-r--r--core/vimrc10
2 files changed, 10 insertions, 3 deletions
diff --git a/core/tmux.conf b/core/tmux.conf
index a1851d0..cc69bb5 100644
--- a/core/tmux.conf
+++ b/core/tmux.conf
@@ -9,6 +9,9 @@ setw -g mode-keys vi
9# Mouse selection 9# Mouse selection
10set -g mouse on 10set -g mouse on
11 11
12# Scrollback lines per pane (new panes only; a full pane is ~5-10 MB, memory is only used as it fills)
13set -g history-limit 10000
14
12# Persistent pane index labels (top-left of each pane's border) 15# Persistent pane index labels (top-left of each pane's border)
13set -g pane-border-status top 16set -g pane-border-status top
14set -g pane-border-format "#P" 17set -g pane-border-format "#P"
diff --git a/core/vimrc b/core/vimrc
index 4ae28ad..fee3ba3 100644
--- a/core/vimrc
+++ b/core/vimrc
@@ -42,13 +42,18 @@ nnoremap <silent> <leader>rg :<C-U>Rg<CR>| " \rg: search tex
42nnoremap <silent> <leader>b :<C-U>Buffers<CR>| " \b: list open buffers 42nnoremap <silent> <leader>b :<C-U>Buffers<CR>| " \b: list open buffers
43nnoremap <silent> <leader>n :<C-U>NERDTreeToggle<CR>| " \n: toggle file tree 43nnoremap <silent> <leader>n :<C-U>NERDTreeToggle<CR>| " \n: toggle file tree
44nnoremap <silent> gd :<C-U>call <SID>GotoDef()<CR>| " gd: go to definition (Ctrl-o back) 44nnoremap <silent> gd :<C-U>call <SID>GotoDef()<CR>| " gd: go to definition (Ctrl-o back)
45nnoremap <silent> gi :<C-U>LspImplementation<CR>| " gi: go to implementation 45nnoremap <silent> gr :<C-U>LspReferences<CR>| " gr: list every place the symbol under the cursor is used (Enter jumps)
46nnoremap <silent> ]r :<C-U>execute v:count1 . 'cnext'<CR>| " ]r: next use from the gr list (across files)
47nnoremap <silent> [r :<C-U>execute v:count1 . 'cprevious'<CR>| " [r: previous use from the gr list
48nnoremap <silent> ]e :<C-U>LspNextDiagnostic<CR>| " ]e: jump to the next error/warning in this file
49nnoremap <silent> [e :<C-U>LspPreviousDiagnostic<CR>| " [e: jump to the previous error/warning in this file
46nnoremap <silent> gy :<C-U>tab LspTypeDefinition<CR>| " gy: go to type definition in a new tab (e -> struct DirEntry) 50nnoremap <silent> gy :<C-U>tab LspTypeDefinition<CR>| " gy: go to type definition in a new tab (e -> struct DirEntry)
47nnoremap <silent> <leader>k :<C-U>call ToggleHover()<CR>| " \k: toggle hover docs 51nnoremap <silent> <leader>k :<C-U>call ToggleHover()<CR>| " \k: toggle hover docs
48nnoremap <silent> K :<C-U>call ToggleHover()<CR>| " K: toggle hover docs (same as \k) 52nnoremap <silent> K :<C-U>call ToggleHover()<CR>| " K: toggle hover docs (same as \k)
49nnoremap <silent> <leader>D :<C-U>LspDocumentation<CR>| " \D: show documentation 53nnoremap <silent> <leader>D :<C-U>LspDocumentation<CR>| " \D: show documentation
50nnoremap <silent> <leader>e :<C-U>call ToggleDiagnostic()<CR>| " \e: show error on this line 54nnoremap <silent> <leader>e :<C-U>call ToggleDiagnostic()<CR>| " \e: show error on this line
51nnoremap <silent> <leader>l :<C-U>lopen<CR>| " \l: list all errors 55nnoremap <silent> <leader>l :<C-U>LspDocumentDiagnostics<CR>| " \l: list errors in this file
56nnoremap <silent> <leader>L :<C-U>LspDocumentDiagnostics --buffers=*<CR>| " \L: list every error the servers know (Rust: whole crate; Python: open files)
52nnoremap <silent> <leader>a :<C-U>LspCodeAction<CR>| " \a: code actions popup 57nnoremap <silent> <leader>a :<C-U>LspCodeAction<CR>| " \a: code actions popup
53nnoremap <silent> <leader>rn :<C-U>LspRename<CR>| " \rn: rename symbol 58nnoremap <silent> <leader>rn :<C-U>LspRename<CR>| " \rn: rename symbol
54nnoremap <silent> <leader>f :<C-U>LspDocumentFormat<CR>| " \f: format file 59nnoremap <silent> <leader>f :<C-U>LspDocumentFormat<CR>| " \f: format file
@@ -179,7 +184,6 @@ Plug 'tpope/vim-surround'
179Plug 'tpope/vim-fugitive' 184Plug 'tpope/vim-fugitive'
180Plug 'airblade/vim-gitgutter' 185Plug 'airblade/vim-gitgutter'
181Plug 'preservim/nerdtree' 186Plug 'preservim/nerdtree'
182Plug 'andymass/vim-matchup'
183call plug#end() 187call plug#end()
184endif 188endif
185 189