From c647d422cd001c7845bcec05c06fdbd54b3efec4 Mon Sep 17 00:00:00 2001 From: xs Date: Mon, 9 Nov 2026 02:27:30 +0800 Subject: 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 --- core/tmux.conf | 3 +++ core/vimrc | 10 +++++++--- 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 # Mouse selection set -g mouse on +# Scrollback lines per pane (new panes only; a full pane is ~5-10 MB, memory is only used as it fills) +set -g history-limit 10000 + # Persistent pane index labels (top-left of each pane's border) set -g pane-border-status top set -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 rg :Rg| " \rg: search tex nnoremap b :Buffers| " \b: list open buffers nnoremap n :NERDTreeToggle| " \n: toggle file tree nnoremap gd :call GotoDef()| " gd: go to definition (Ctrl-o back) -nnoremap gi :LspImplementation| " gi: go to implementation +nnoremap gr :LspReferences| " gr: list every place the symbol under the cursor is used (Enter jumps) +nnoremap ]r :execute v:count1 . 'cnext'| " ]r: next use from the gr list (across files) +nnoremap [r :execute v:count1 . 'cprevious'| " [r: previous use from the gr list +nnoremap ]e :LspNextDiagnostic| " ]e: jump to the next error/warning in this file +nnoremap [e :LspPreviousDiagnostic| " [e: jump to the previous error/warning in this file nnoremap gy :tab LspTypeDefinition| " gy: go to type definition in a new tab (e -> struct DirEntry) nnoremap k :call ToggleHover()| " \k: toggle hover docs nnoremap K :call ToggleHover()| " K: toggle hover docs (same as \k) nnoremap D :LspDocumentation| " \D: show documentation nnoremap e :call ToggleDiagnostic()| " \e: show error on this line -nnoremap l :lopen| " \l: list all errors +nnoremap l :LspDocumentDiagnostics| " \l: list errors in this file +nnoremap L :LspDocumentDiagnostics --buffers=*| " \L: list every error the servers know (Rust: whole crate; Python: open files) nnoremap a :LspCodeAction| " \a: code actions popup nnoremap rn :LspRename| " \rn: rename symbol nnoremap f :LspDocumentFormat| " \f: format file @@ -179,7 +184,6 @@ Plug 'tpope/vim-surround' Plug 'tpope/vim-fugitive' Plug 'airblade/vim-gitgutter' Plug 'preservim/nerdtree' -Plug 'andymass/vim-matchup' call plug#end() endif -- cgit