From 6d52315dbce8f1a83c22b6d340d4f178ad7767fd Mon Sep 17 00:00:00 2001 From: Robin Krahl Date: Sun, 12 Mar 2017 20:45:40 +0100 Subject: vim: use .config/vim and .cache/vim instead of .vim --- .config/vim/after/ftplugin/cpp.vim | 5 ++++ .config/vim/ftdetect/cls.vim | 1 + .config/vim/ftplugin/c.vim | 8 ++++++ .config/vim/ftplugin/mail.vim | 2 ++ .config/vim/ftplugin/tex.vim | 5 ++++ .gitmodules | 3 --- .vim/after/ftplugin/cpp.vim | 5 ---- .vim/after/ftplugin/cs.vim | 3 --- .vim/bundle/Vundle.vim | 1 - .vim/ftdetect/cls.vim | 1 - .vim/ftdetect/mutt.vim | 1 - .vim/ftplugin/c.vim | 8 ------ .vim/ftplugin/mail.vim | 2 -- .vim/ftplugin/tex.vim | 5 ---- .vim/vimrc | 50 -------------------------------------- .vimrc | 40 ++++++++++++++++++++++++++++++ 16 files changed, 61 insertions(+), 79 deletions(-) create mode 100644 .config/vim/after/ftplugin/cpp.vim create mode 100644 .config/vim/ftdetect/cls.vim create mode 100644 .config/vim/ftplugin/c.vim create mode 100644 .config/vim/ftplugin/mail.vim create mode 100644 .config/vim/ftplugin/tex.vim delete mode 100644 .gitmodules delete mode 100644 .vim/after/ftplugin/cpp.vim delete mode 100644 .vim/after/ftplugin/cs.vim delete mode 160000 .vim/bundle/Vundle.vim delete mode 100644 .vim/ftdetect/cls.vim delete mode 100644 .vim/ftdetect/mutt.vim delete mode 100644 .vim/ftplugin/c.vim delete mode 100644 .vim/ftplugin/mail.vim delete mode 100644 .vim/ftplugin/tex.vim delete mode 100644 .vim/vimrc create mode 100644 .vimrc diff --git a/.config/vim/after/ftplugin/cpp.vim b/.config/vim/after/ftplugin/cpp.vim new file mode 100644 index 0000000..0e18e2e --- /dev/null +++ b/.config/vim/after/ftplugin/cpp.vim @@ -0,0 +1,5 @@ +setlocal expandtab +setlocal shiftwidth=4 +setlocal softtabstop=4 + +setlocal cino=N-s diff --git a/.config/vim/ftdetect/cls.vim b/.config/vim/ftdetect/cls.vim new file mode 100644 index 0000000..1a23087 --- /dev/null +++ b/.config/vim/ftdetect/cls.vim @@ -0,0 +1 @@ +au BufNewFile,BufRead *.cls set filetype=tex diff --git a/.config/vim/ftplugin/c.vim b/.config/vim/ftplugin/c.vim new file mode 100644 index 0000000..beaaf90 --- /dev/null +++ b/.config/vim/ftplugin/c.vim @@ -0,0 +1,8 @@ +setlocal tabstop=8 +setlocal softtabstop=8 +setlocal shiftwidth=8 +setlocal noexpandtab + +setlocal cino=:0 + +setlocal colorcolumn=80 diff --git a/.config/vim/ftplugin/mail.vim b/.config/vim/ftplugin/mail.vim new file mode 100644 index 0000000..0915315 --- /dev/null +++ b/.config/vim/ftplugin/mail.vim @@ -0,0 +1,2 @@ +setlocal noexpandtab +setlocal wrap diff --git a/.config/vim/ftplugin/tex.vim b/.config/vim/ftplugin/tex.vim new file mode 100644 index 0000000..40e8bf7 --- /dev/null +++ b/.config/vim/ftplugin/tex.vim @@ -0,0 +1,5 @@ +setlocal tabstop=2 +setlocal shiftwidth=2 +setlocal expandtab + +setlocal colorcolumn=80 diff --git a/.gitmodules b/.gitmodules deleted file mode 100644 index a9995d5..0000000 --- a/.gitmodules +++ /dev/null @@ -1,3 +0,0 @@ -[submodule ".vim/bundle/Vundle.vim"] - path = .vim/bundle/Vundle.vim - url = https://github.com/Vundlevim/Vundle.vim diff --git a/.vim/after/ftplugin/cpp.vim b/.vim/after/ftplugin/cpp.vim deleted file mode 100644 index 0e18e2e..0000000 --- a/.vim/after/ftplugin/cpp.vim +++ /dev/null @@ -1,5 +0,0 @@ -setlocal expandtab -setlocal shiftwidth=4 -setlocal softtabstop=4 - -setlocal cino=N-s diff --git a/.vim/after/ftplugin/cs.vim b/.vim/after/ftplugin/cs.vim deleted file mode 100644 index 765e06c..0000000 --- a/.vim/after/ftplugin/cs.vim +++ /dev/null @@ -1,3 +0,0 @@ -setlocal expandtab -setlocal shiftwidth=4 -setlocal softtabstop=4 diff --git a/.vim/bundle/Vundle.vim b/.vim/bundle/Vundle.vim deleted file mode 160000 index 4984767..0000000 --- a/.vim/bundle/Vundle.vim +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 4984767509e3d05ca051e253c8a8b37de784be45 diff --git a/.vim/ftdetect/cls.vim b/.vim/ftdetect/cls.vim deleted file mode 100644 index 1a23087..0000000 --- a/.vim/ftdetect/cls.vim +++ /dev/null @@ -1 +0,0 @@ -au BufNewFile,BufRead *.cls set filetype=tex diff --git a/.vim/ftdetect/mutt.vim b/.vim/ftdetect/mutt.vim deleted file mode 100644 index 9b67c41..0000000 --- a/.vim/ftdetect/mutt.vim +++ /dev/null @@ -1 +0,0 @@ -au BufNewFile,BufRead */.mutt/* set filetype=muttrc diff --git a/.vim/ftplugin/c.vim b/.vim/ftplugin/c.vim deleted file mode 100644 index beaaf90..0000000 --- a/.vim/ftplugin/c.vim +++ /dev/null @@ -1,8 +0,0 @@ -setlocal tabstop=8 -setlocal softtabstop=8 -setlocal shiftwidth=8 -setlocal noexpandtab - -setlocal cino=:0 - -setlocal colorcolumn=80 diff --git a/.vim/ftplugin/mail.vim b/.vim/ftplugin/mail.vim deleted file mode 100644 index 0915315..0000000 --- a/.vim/ftplugin/mail.vim +++ /dev/null @@ -1,2 +0,0 @@ -setlocal noexpandtab -setlocal wrap diff --git a/.vim/ftplugin/tex.vim b/.vim/ftplugin/tex.vim deleted file mode 100644 index 40e8bf7..0000000 --- a/.vim/ftplugin/tex.vim +++ /dev/null @@ -1,5 +0,0 @@ -setlocal tabstop=2 -setlocal shiftwidth=2 -setlocal expandtab - -setlocal colorcolumn=80 diff --git a/.vim/vimrc b/.vim/vimrc deleted file mode 100644 index 0db9545..0000000 --- a/.vim/vimrc +++ /dev/null @@ -1,50 +0,0 @@ -" Initialize Vundle for plugin management - -set nocompatible -filetype off - -set rtp+=~/.vim/bundle/Vundle.vim -call vundle#begin() -Plugin 'VundleVim/Vundle.vim' -Plugin 'a.vim' -Plugin 'andreasvc/vim-256noir' -Plugin 'aperezdc/vim-template' -Plugin 'cespare/vim-toml' -Plugin 'ctrlpvim/ctrlp.vim' -Plugin 'godlygeek/tabular' -Plugin 'LucHermitte/lh-vim-lib' -Plugin 'LucHermitte/local_vimrc' -Plugin 'OmniSharp/omnisharp-vim' -Plugin 'rodjek/vim-puppet' -Plugin 'rust-lang/rust.vim' -Plugin 'scrooloose/syntastic' -Plugin 'tpope/vim-dispatch' -Plugin 'tpope/vim-fugitive' -call vundle#end() - -filetype plugin indent on - -runtime! ftplugin/man.vim - -" Syntax highlighting -syntax on - -" Status line and numbers -set laststatus=2 -set number - -" Colors -set background=dark - -" LaTeX instead of Plain TeX -let g:tex_flavor = "latex" - -" Temporary workaround: csproj indicates a project root -let g:ctrlp_root_markers = ['*.csproj'] - -" Ignore some additional patterns when opening files -" set wildignore+=*/tmp/*,*.so,*.swp,*.zip,*/vendor/*,*/node_modules/* -set wildignore+=*.so,*.swp,*.zip,*/vendor/*,*/node_modules/* - -" Set viminfo path according to XDG Base Directory specification -set viminfo+=n~/.cache/vim/viminfo diff --git a/.vimrc b/.vimrc new file mode 100644 index 0000000..c298e8d --- /dev/null +++ b/.vimrc @@ -0,0 +1,40 @@ +" Disable Vi-compatibility +set nocompatible + +" Set paths according to XDG Base Directory specification +set viminfo+=n${XDG_CACHE_HOME}/vim/viminfo +set runtimepath=${XDG_CONFIG_HOME}/vim,${XDG_CONFIG_HOME}/vim/after,$VIM,$VIMRUNTIME + +" Syntax highlighting +syntax on + +" Enable the filetype plugin +filetype plugin indent on +" LaTeX instead of Plain TeX +let g:tex_flavor = "latex" + +" Status line and numbers +set laststatus=2 +set number +set relativenumber +set ruler + +" Colors +set background=dark + +" Ignore some additional patterns when opening files +set wildignore+=*.o,*.so,*.swp + +" Search subdirectories with :find & co +set path+=** + +" Better completion +set wildmenu +set wildmode=longest:full,full + +" netrw +let g:netrw_banner=0 +" let g:netrw_browse_split=4 +let g:netrw_altv=1 +let g:netrw_liststyle=3 +let g:netrw_list_hide=netrw_gitignore#Hide() -- cgit v1.2.3