From 6560ce1b95bc8ed06867d45401c7a4b2f3f59524 Mon Sep 17 00:00:00 2001 From: 0scar Date: Thu, 16 Nov 2023 16:31:56 +0100 Subject: Update vimrc --- .config/vim/vimrc | 34 ++++++++++++++++++++++++++++------ 1 file changed, 28 insertions(+), 6 deletions(-) (limited to '.config/vim') diff --git a/.config/vim/vimrc b/.config/vim/vimrc index c304db9..fec98ae 100644 --- a/.config/vim/vimrc +++ b/.config/vim/vimrc @@ -23,18 +23,19 @@ if !has('nvim') if has('viminfo') set viminfo=%,'10,<10,/200,:200,h,n$XDG_CACHE_HOME/vim/.viminfo endif - set runtimepath=$XDG_CONFIG_HOME/vim,$XDG_CONFIG_HOME/vim/after,$VIM,$VIMRUNTIME,$VIM/vimfiles,$VIM/vimfiles/after,$VIM/vimfiles/plugin " Fix shift-tab exe 'set t_kB=' . nr2char(27) . '[Z' " Everything apparently breaks (in Neovim) if setting background = dark - "set bg=dark + set bg=dark syntax enable filetype plugin indent on endif +set runtimepath=$XDG_CONFIG_HOME/vim,$XDG_CONFIG_HOME/vim/after,$VIM,$VIMRUNTIME,$VIM/vimfiles,$VIM/vimfiles/after,$VIM/vimfiles/plugin + " behaviour set history=1024 set wildmenu @@ -136,6 +137,9 @@ nnoremap l imap A imap I +cmap +cmap + " Search for VISUAL-highlighted text (very brittle) vmap // y/\V" @@ -159,8 +163,12 @@ vnoremap { `>a}` "" Plugin settings " junegunn/fzf.vim bindings -"noremap :Files -"noremap :Buffers +noremap :Files +noremap :Buffers + +"" Alternatively use telescope (if on neovim) +"noremap :Telescope find_files +"noremap :Telescope buffers " lervag/vimtex let g:tex_flavor='latex' @@ -183,7 +191,7 @@ let g:latex_view_general_viewer = 'zathura' let g:vimtex_view_method = 'zathura' " tpope/vim-markdown specific settings -"let g:markdown_fenced_languages = ['c', 'css', 'sh', 'vim', 'futhark'] +let g:markdown_fenced_languages = ['c', 'css', 'sh', 'vim', 'futhark', 'haskell'] "if has("autocmd") @@ -260,4 +268,18 @@ if has('nvim') call plug#end() endif -colorscheme night-owl +"autocmd FileType markdown +" \ set formatoptions-=q | +" \ set formatlistpat=^\\s*\\d\\+\\.\\s\\+\\\|^\\s*\[-*+]\\s\\+ + +autocmd FileType markdown set comments-=mb:* +autocmd FileType markdown set comments-=mb:+ +autocmd FileType markdown set comments-=mb:- +autocmd FileType markdown set formatlistpat=^\\s*\\d\\+\\.\\s\\+\\\|^\\s*\[-*+]\\s\\+ + + +if has('nvim') + colorscheme night-owl +else + colorscheme tokyonight +endif -- cgit v1.3