Packages changes an newly added settings.

This commit is contained in:
Sebastian 2021-03-12 16:02:34 +01:00
parent eec591f5dd
commit bd71d64c37

View file

@ -18,6 +18,8 @@ call plug#begin('~/.vim/bundle')
Plug 'airblade/vim-gitgutter' Plug 'airblade/vim-gitgutter'
Plug 'artur-shaik/vim-javacomplete2' Plug 'artur-shaik/vim-javacomplete2'
Plug 'chauncey-garrett/vim-tasklist' Plug 'chauncey-garrett/vim-tasklist'
Plug 'Yggdroot/indentLine'
Plug 'preservim/nerdcommenter'
Plug 'ctrlpvim/ctrlp.vim' Plug 'ctrlpvim/ctrlp.vim'
Plug 'davidhalter/jedi-vim' Plug 'davidhalter/jedi-vim'
Plug 'dense-analysis/ale' Plug 'dense-analysis/ale'
@ -37,7 +39,7 @@ Plug 'tpope/vim-fugitive'
Plug 'tpope/vim-surround' Plug 'tpope/vim-surround'
Plug 'vim-airline/vim-airline' Plug 'vim-airline/vim-airline'
Plug 'vim-airline/vim-airline-themes' Plug 'vim-airline/vim-airline-themes'
Plug 'Yilin-Yang/vim-markbar' " Plug 'Yilin-Yang/vim-markbar' "Does not work that good, seems too buggy atm
call plug#end() call plug#end()
@ -50,7 +52,7 @@ set backspace=2 " Backspace deletes like most programs in insert mode
set nobackup set nobackup
set nowritebackup set nowritebackup
set noswapfile " http://robots.thoughtbot.com/post/18739402579/global-gitignore#comment-458413287 set noswapfile " http://robots.thoughtbot.com/post/18739402579/global-gitignore#comment-458413287
set history=50 set history=200
set ruler " show the cursor position all the time set ruler " show the cursor position all the time
set showcmd " display incomplete commands set showcmd " display incomplete commands
set incsearch " do incremental searching set incsearch " do incremental searching
@ -131,7 +133,7 @@ set nojoinspaces
"endif "endif
" Make it obvious where 80 characters is " Make it obvious where 80 characters is
autocmd FileType python setlocal textwidth=80 colorcolumn=+1 " autocmd FileType python setlocal textwidth=80 colorcolumn=+1
" Numbers " Numbers
set number set number
@ -181,6 +183,10 @@ set ignorecase
set smartcase set smartcase
set hlsearch set hlsearch
" Search replace bind:
nnoremap S :%s//g<Left><Left>
" Strip trailing whitespaces on each save " Strip trailing whitespaces on each save
fun! <SID>StripTrailingWhitespaces() fun! <SID>StripTrailingWhitespaces()
let l = line(".") let l = line(".")
@ -258,7 +264,8 @@ let g:ale_fixers = {'python': ['isort', 'black'],
" Install the linter and fixer for a specific language automatically " Install the linter and fixer for a specific language automatically
command InstallLinterFixPython python3 import pip; [pip.main(["install", singlepackage, "--user"]) for singlepackage in "flake8 pylint mypy prospector black isort".split(" ")] "todo Find better solution to do this
" command InstallLinterFixPython python3 import pip; [pip.main(["install", singlepackage, "--user"]) for singlepackage in "flake8 pylint mypy prospector black isort".split(" ")]
" colorscheme toggle: " colorscheme toggle:
@ -291,8 +298,25 @@ augroup python_syntax_extra
autocmd! Syntax python :syn keyword Keyword self autocmd! Syntax python :syn keyword Keyword self
augroup END augroup END
" Bind ctrl+u to jump list jump (opposite of ctrl+o) " Bind ctrl+u to jump list jump (opposite of ctrl+o)
nnoremap <C-u> <C-i> nnoremap <C-u> <C-i>
" Load changes to a file automatically from drive if the file has not been
" changed yet
set autoread
" Generate help tags to find the docs with :help
"if !empty((globpath(&rtp, '~/.vim/doc/**'))
" helptags ~/.vim/doc
"endif
" Use persistent history. (so undo from older sessions can be used)
if !isdirectory("$HOME/.vim/.vim-undo-dir")
silent !mkdir -p $HOME/.vim/.vim-undo-dir
endif
set undodir=$HOME/.vim/.vim-undo-dir
set undofile
" Set the character which is used as tab indent marker
let g:indentLine_char = '┊'