Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- "
- " init.vim by Felipe Ramos
- " for neovim
- "
- " Plugins {{{
- call plug#begin()
- Plug 'chriskempson/base16-vim'
- Plug 'mhinz/vim-startify'
- " Plug 'octol/vim-cpp-enhanced-highlight'
- " Plug 'joshdick/onedark.vim'
- Plug 'tpope/vim-sensible'
- Plug 'vim-airline/vim-airline'
- Plug 'vim-airline/vim-airline-themes'
- Plug 'vim-syntastic/syntastic'
- Plug 'sheerun/vim-polyglot'
- Plug 'scrooloose/nerdcommenter'
- " Plug 'scrooloose/nerdtree'
- Plug 'powerline/powerline'
- " Plug 'rafi/awesome-vim-colorschemes'
- " Plug 'chriskempson/base16-vim'
- Plug 'terryma/vim-multiple-cursors'
- Plug 'jiangmiao/auto-pairs'
- " Plug 'whatyouhide/vim-lengthmatters'
- " Plug 'jlanzarotta/bufexplorer'
- " Plug 'mhartington/oceanic-next'
- call plug#end()
- "}}}
- " Aesthetic configurations {{{
- " Something related to 256 color rendering
- if has('nvim') || has('termguicolors')
- set termguicolors
- endif
- syntax enable
- let base16colorspace=256
- colo base16-tomorrow-night
- " oceanic-next theme
- " let g:oceanic_next_terminal_bold = 1
- " let g:oceanic_next_terminal_italic = 1
- " colo OceanicNext
- " if filereadable(expand("~/.vimrc_background"))
- " let base16colorspace=256
- " source ~/.vimrc_background
- " endif
- "}}}
- " Custom set's {{{
- filetype plugin on
- " Path related
- set path+=**
- set wildmenu
- set directory=$HOME/.vim/swp_files//
- " Show cms while they're typed
- set showcmd
- " Tab = 4 spaces
- set tabstop=4
- set shiftwidth=4
- set expandtab " Substitutes by spaces
- set autoindent
- " Line numbers on the left
- set number
- " set relativenumber
- set nowrap " disables wrap's
- " Enable system clipboard with yank / paste. Like *"y
- set clipboard+=unnamed
- " Indicator on 80 char
- set cc=80
- " Get this really cool folding
- set foldmethod=marker
- " When using on a GUI, use this font
- set guifont=DejaVu\ Sans\ Mono\ for\ Powerline:h14
- " Highligh the current line
- " set cursorline
- "}}}
- " Plugins settings {{{
- " [off] PBCOPY AND PBPASTE settings ( Only works in macOS ) {{{
- " NOT NECESSARY WITH +clipboard VERSION
- " vnoremap <C-c> :w !pbcopy<CR><CR>
- " vnoremap <C-v> :r !pbpaste<CR><CR>
- "}}}
- " [on] vim-instant-markdown config {{{
- let g:instant_markdown_slow = 1
- let g:instant_markdown_autostart = 0
- " Keymap for enable the instantMarkdownPrevie (Opens a chrome window)
- nmap <M-p> :InstantMarkdownPreview<CR>
- " }}}
- " [on] Syntastic Settings {{{
- let g:syntastic_check_on_open = 1
- let g:syntastic_error_symbol = ">>"
- let g:syntastic_warning_symbol = "~"
- let g:syntastic_always_populate_loc_list = 1
- let g:syntastic_python_checkers= ["flake8"]
- " }}}
- " [off] Ale settings {{{
- " let g:airline#extensions#ale#enabled = 1
- " let g:ale_sign_error = '>>'
- " let g:ale_sign_warning = '~'
- " let g:ale_completion_enabled = 1
- " let g:ale_lint_delay = 1000
- " let g:ale_lint_on_text_changed = 'normal'
- " let g:ale_linters = {
- " \ 'python': ['flake8'],
- " \}
- "}}}
- " [off] NERDTree settings {{{
- " Autostart when no file is specified
- " autocmd StdinReadPre * let s:std_in=1
- " autocmd VimEnter * if argc() == 0 && !exists("s:std_in") | NERDTree | endif
- " " Ctrl + N Toggle NERDTree
- " map <C-k> :NERDTreeToggle<CR>
- "}}}
- " [on] Buffer explorer settings {{{
- " nmap <leader>b :BufExplorer<CR>
- "}}}
- " [on] Powerline settings {{{
- set rtp+=/usr/local/lib/python2.7/site-packages/powerline/bindings/vim
- " let g:airline_powerline_fonts = 1
- "}}}
- " [on] Airline settings {{{
- let g:airline_detect_paste=1
- let g:airline#extensions#tabline#enabled = 1
- " let g:airline_theme='onedark'
- " let g:airline_theme='oceanicnext'
- "}}}
- " [on] NERDCommenter settings {{{
- " Add spaces after comment delimiters by default
- let g:NERDSpaceDelims = 1
- " Use compact syntax for prettified multi-line comments
- let g:NERDCompactSexyComs = 1
- " Align line-wise comment delimiters flush left instead of following code indentation
- let g:NERDDefaultAlign = 'left'
- " Set a language to use its alternate delimiters by default
- let g:NERDAltDelims_java = 1
- " Add your own custom formats or override the defaults
- let g:NERDCustomDelimiters = { 'c': { 'left': '/**','right': '*/' } }
- " Allow commenting and inverting empty lines (useful when commenting a region)
- let g:NERDCommentEmptyLines = 0
- " Enable trimming of trailing whitespace when uncommenting
- let g:NERDTrimTrailingWhitespace = 1
- "}}}
- " [on] NERDTree settings {{{
- map <C-b> :NERDTreeToggle<CR>
- "}}}
- " [off] Navigate thru panes using Command + H J K L {{{
- " nnoremap <C-J> <C-W><C-J>
- " nnoremap <C-K> <C-W><C-K>
- " nnoremap <C-L> <C-W><C-L>
- " nnoremap <C-H> <C-W><C-H>
- "}}}
- " [on] AutoPairs settings {{{
- let g:AutoPairsShortcutToggle = '<M-a>'
- "}}}
- " [on] vim-cpp-enhanced-highlight settings {{{
- let g:cpp_class_scope_highlight = 1
- let g:cpp_member_variable_highlight = 1
- let g:cpp_class_decl_highlight = 1
- let g:cpp_concepts_highlight = 1
- "}}}
- " vim-multiple-cursors settings {{{
- " let g:multi_cursor_use_default_mapping=0
- " Default mapping
- " let g:multi_cursor_start_word_key = '<C-n>'
- " let g:multi_cursor_select_all_word_key = '<A-n>'
- " let g:multi_cursor_start_key = 'g<C-n>'
- " let g:multi_cursor_select_all_key = 'g<A-n>'
- " let g:multi_cursor_next_key = '<C-n>'
- " let g:multi_cursor_prev_key = '<C-p>'
- " let g:multi_cursor_skip_key = '<C-x>'
- " let g:multi_cursor_quit_key = '<Esc>'
- " let g:multi_cursor_start_word_key = '<M-n>'
- " let g:multi_cursor_select_all_word_key = '<A-n>'
- " let g:multi_cursor_start_key = 'g<C-n>'
- " let g:multi_cursor_select_all_key = 'g<A-n>'
- " let g:multi_cursor_next_key = '<M-n>'
- " let g:multi_cursor_prev_key = '<M-p>'
- " let g:multi_cursor_skip_key = '<M-x>'
- " let g:multi_cursor_quit_key = '<Esc>'
- "}}}
- "}}}
- " Custom mappings {{{
- " Auto compile C++ individual files
- nmap <M-r> :!g++ % -o %< --std=c++11 && ./%<<CR>
- " Snippet for creating simple C++ files
- nmap <M-i> i#include <iostream><CR><CR>int main(int argc, char **argv){<CR>return 0;}<Esc>kO
- "}}}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement