set tabstop=4 shiftwidth=4 noexpandtab ai nosmd ignorecase smartcase " terminal settings " disable line numbers au TermOpen * setlocal nonumber norelativenumber " make ESC go to normal mode tnoremap " sign column on top of the line number (gutter for things like breakpoints, warnings) set scl=number " enable line numbers set number relativenumber " disable bottom right status line set noruler set showtabline=0 " performance? set lazyredraw nocursorline ttyfast " use system clipboard instead of internal set clipboard=unnamedplus " when using c or s, do not overwrite clipboard nnoremap c "-c nnoremap s "-s let mapleader = "," set shell=/bin/sh hi Search cterm=NONE ctermfg=white ctermbg=blue hi StatusLine ctermbg=NONE cterm=italic hi SignColumn ctermbg=NONE autocmd InsertEnter * hi StatusLine cterm=bold autocmd InsertLeave * hi StatusLine cterm=italic highlight LineNr ctermfg=grey " Disable highlighting when searching nnoremap :noh " shortcuts to type symbols easier source $XDG_CONFIG_HOME/nvim/digraphs.vim vnoremap K :'<,'>Evaluate " tab, window management set splitbelow splitright nnoremap w nnoremap W nnoremap :vertical resize -5 nnoremap :vertical resize +5 " exit all (akin to ZZ, ZQ) nnoremap ZF :qa " copy URL under cursor to clipboard bind :nnoremap uu :let @+ = expand('') " Plugins " Run PlugInstall if there are missing plugins if $SYSTEM_PROFILE == "DEFAULT" autocmd VimEnter * if len(filter(values(g:plugs), '!isdirectory(v:val.dir)')) \| PlugInstall --sync | source $MYVIMRC \| endif endif " The rest will not be sourced if the system is on minimal settings. if $SYSTEM_PROFILE == "MINIMAL" finish endif call plug#begin() filetype plugin indent on " i don't use LaTeX anymore, but you can uncomment this to "source $XDG_CONFIG_HOME/nvim/vimtex.vim source $XDG_CONFIG_HOME/nvim/ultisnips.vim if $SYSTEM_PROFILE == "DEFAULT" " notes and documents stuff source $XDG_CONFIG_HOME/nvim/typst.vim " plugins for IDE-like nvim source $XDG_CONFIG_HOME/nvim/coding.vim endif " URL motions Plug 'axieax/urlview.nvim' " fancy motions Plug 'ggandor/leap.nvim' call plug#end() if $SYSTEM_PROFILE == "DEFAULT" " see .config/nvim/lua/init.lua lua require('init') endif