mirror of
https://github.com/nmasur/dotfiles
synced 2024-11-25 21:55:37 +00:00
vim cleanup
This commit is contained in:
parent
882d8c75fa
commit
281f2a5a86
@ -14,5 +14,4 @@ brew "noti" # Create system notifications
|
|||||||
brew "b2-tools" # BackBlaze B2 storage
|
brew "b2-tools" # BackBlaze B2 storage
|
||||||
brew "cjbassi/ytop/ytop" # Fancy system performance
|
brew "cjbassi/ytop/ytop" # Fancy system performance
|
||||||
brew "nmasur/repo/update-ssh-config" # Update .ssh/config
|
brew "nmasur/repo/update-ssh-config" # Update .ssh/config
|
||||||
brew "kakoune" # Modal editor
|
|
||||||
brew "awslogs" # View AWS log streams
|
brew "awslogs" # View AWS log streams
|
||||||
|
@ -11,13 +11,9 @@ command! Today exe 'edit ~/notes/journal/'.strftime("%Y-%m-%d_%a").'.md'
|
|||||||
" Map the leader key
|
" Map the leader key
|
||||||
map <Space> <Leader>
|
map <Space> <Leader>
|
||||||
|
|
||||||
"This unsets the `last search pattern` register by hitting return
|
" Unsets the search pattern register by hitting return
|
||||||
nnoremap <silent> <CR> :noh<CR><CR>
|
nnoremap <silent> <CR> :noh<CR><CR>
|
||||||
|
|
||||||
" Find and replace
|
|
||||||
nnoremap <Leader>S :%s/
|
|
||||||
vnoremap <leader>S :s/
|
|
||||||
|
|
||||||
" Shuffle lines around
|
" Shuffle lines around
|
||||||
nnoremap <A-j> :m .+1<CR>==
|
nnoremap <A-j> :m .+1<CR>==
|
||||||
nnoremap <A-k> :m .-2<CR>==
|
nnoremap <A-k> :m .-2<CR>==
|
||||||
@ -63,15 +59,9 @@ nnoremap <Leader><Tab> :b#<cr>
|
|||||||
" Jump to text in this file
|
" Jump to text in this file
|
||||||
nnoremap <Leader>s :BLines<cr>
|
nnoremap <Leader>s :BLines<cr>
|
||||||
|
|
||||||
" Start Magit buffer
|
|
||||||
nnoremap <Leader>gs :Magit<cr>
|
|
||||||
|
|
||||||
" Toggle Git gutter (by line numbers)
|
" Toggle Git gutter (by line numbers)
|
||||||
nnoremap <Leader>` :GitGutterToggle<cr>
|
nnoremap <Leader>` :GitGutterToggle<cr>
|
||||||
|
|
||||||
" Git push
|
|
||||||
nnoremap <Leader>gp :Git push<cr>
|
|
||||||
|
|
||||||
" Git repo
|
" Git repo
|
||||||
nnoremap <silent> <Leader>gr :!gh repo view -w<cr><cr>
|
nnoremap <silent> <Leader>gr :!gh repo view -w<cr><cr>
|
||||||
|
|
||||||
@ -105,9 +95,6 @@ tnoremap <A-CR> <C-\><C-n>
|
|||||||
nnoremap <Leader>rr :Refresh<cr>
|
nnoremap <Leader>rr :Refresh<cr>
|
||||||
nnoremap <Leader>rp :Refresh<cr> :PlugInstall<cr>
|
nnoremap <Leader>rp :Refresh<cr> :PlugInstall<cr>
|
||||||
|
|
||||||
" Open file tree
|
|
||||||
nnoremap <silent> <Leader>ft :Fern . -drawer -width=35 -toggle<CR><C-w>=
|
|
||||||
|
|
||||||
" Tabularize
|
" Tabularize
|
||||||
noremap <Leader>ta :Tabularize /
|
noremap <Leader>ta :Tabularize /
|
||||||
noremap <Leader>t# :Tabularize /#<CR>
|
noremap <Leader>t# :Tabularize /#<CR>
|
||||||
|
@ -20,10 +20,10 @@ set smartcase " Check case when using capitals in search
|
|||||||
set infercase " Don't match cases when completing suggestions
|
set infercase " Don't match cases when completing suggestions
|
||||||
set incsearch " Search while typing
|
set incsearch " Search while typing
|
||||||
set visualbell " No sounds
|
set visualbell " No sounds
|
||||||
set scrolljump=1 " Scroll more than one line (or 1 line)
|
set scrolljump=1 " Number of lines to scroll
|
||||||
set scrolloff=3 " Margin of lines when to start scrolling
|
set scrolloff=3 " Margin of lines to see while scrolling
|
||||||
set splitright " Vertical splits on the right side
|
set splitright " Vertical splits on the right side
|
||||||
set splitbelow " Horizontal splits on the lower side
|
set splitbelow " Horizontal splits on the bottom side
|
||||||
set pastetoggle=<F3> " Use F3 to enter raw paste mode
|
set pastetoggle=<F3> " Use F3 to enter raw paste mode
|
||||||
set clipboard+=unnamedplus " Uses system clipboard for yanking
|
set clipboard+=unnamedplus " Uses system clipboard for yanking
|
||||||
set updatetime=300 " Faster diagnostics
|
set updatetime=300 " Faster diagnostics
|
||||||
|
@ -13,25 +13,24 @@ call plug#begin('$HOME/.config/nvim/plugged')
|
|||||||
|
|
||||||
" Core plugins
|
" Core plugins
|
||||||
Plug 'morhetz/gruvbox' " Colorscheme
|
Plug 'morhetz/gruvbox' " Colorscheme
|
||||||
Plug 'junegunn/fzf', { 'do': { -> fzf#install() } } " Required for fuzzyfinder
|
Plug 'junegunn/fzf', { 'do': { -> fzf#install() } } " Install fzf (required)
|
||||||
Plug 'junegunn/fzf.vim' " Actual fuzzyfinder
|
Plug 'junegunn/fzf.vim' " Actual fuzzyfinder
|
||||||
Plug 'tpope/vim-surround' " Enables paren editing
|
Plug 'tpope/vim-surround' " Enables paren editing
|
||||||
Plug 'sheerun/vim-polyglot' " Syntax for every language
|
Plug 'sheerun/vim-polyglot' " Syntax for every language
|
||||||
Plug 'airblade/vim-gitgutter' " Git next to line numbers
|
Plug 'airblade/vim-gitgutter' " Git next to line numbers
|
||||||
Plug 'tpope/vim-commentary' " Use gc or gcc to comment
|
Plug 'tpope/vim-commentary' " Use gc or gcc to comment
|
||||||
Plug 'godlygeek/tabular' " Spacing and alignment
|
Plug 'phaazon/hop.nvim' " Quick jump around the buffer
|
||||||
|
|
||||||
" Ancillary plugins
|
" Ancillary plugins
|
||||||
|
Plug 'godlygeek/tabular' " Spacing and alignment
|
||||||
Plug 'unblevable/quick-scope' " Hints for f and t
|
Plug 'unblevable/quick-scope' " Hints for f and t
|
||||||
Plug 'vimwiki/vimwiki' " Wiki Markdown System
|
Plug 'vimwiki/vimwiki' " Wiki Markdown System
|
||||||
Plug 'jreybert/vimagit' " Git 'gui' buffer
|
|
||||||
Plug 'airblade/vim-rooter' " Change directory to git route
|
Plug 'airblade/vim-rooter' " Change directory to git route
|
||||||
Plug 'tpope/vim-fugitive' " Other git commands
|
Plug 'tpope/vim-fugitive' " Other git commands
|
||||||
Plug 'machakann/vim-highlightedyank' " Highlight text when copied
|
Plug 'machakann/vim-highlightedyank' " Highlight text when copied
|
||||||
Plug 'itchyny/lightline.vim' " Status bar
|
Plug 'itchyny/lightline.vim' " Status bar
|
||||||
Plug 'tpope/vim-eunuch' " File manipulation in Vim
|
Plug 'tpope/vim-eunuch' " File manipulation in Vim
|
||||||
Plug 'tpope/vim-vinegar' " Fixes netrw file explorer
|
Plug 'tpope/vim-vinegar' " Fixes netrw file explorer
|
||||||
Plug 'lambdalisue/fern.vim' " File explorer / project drawer
|
|
||||||
Plug 'christoomey/vim-tmux-navigator' " Hotkeys for tmux panes
|
Plug 'christoomey/vim-tmux-navigator' " Hotkeys for tmux panes
|
||||||
|
|
||||||
" CoC (Language Server Protocol, requires NodeJS)
|
" CoC (Language Server Protocol, requires NodeJS)
|
||||||
|
Loading…
Reference in New Issue
Block a user