Skip to content

Instantly share code, notes, and snippets.

@aflashyrhetoric
Last active May 1, 2019 13:52
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save aflashyrhetoric/d0b1c9a5e3716f08f4c8 to your computer and use it in GitHub Desktop.
Save aflashyrhetoric/d0b1c9a5e3716f08f4c8 to your computer and use it in GitHub Desktop.
LOL
"----------------Vundle Stuff ------------------"
set nocompatible " be iMproved, required
filetype off " required
" set the runtime path to include Vundle and initialize
set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()
"call vundle#begin('~/some/path/here')
" - Go To Plugins
"-----------------------------------------------------------
" let Vundle manage Vundle, required
Plugin 'VundleVim/Vundle.vim'
"Plugin 'tpope/vim-vinegar'
Plugin 'scrooloose/nerdtree'
Plugin 'tpope/vim-surround'
Plugin 'kien/ctrlp.vim'
Plugin 'scrooloose/nerdcommenter'
Plugin 'mattn/emmet-vim'
Plugin 'terryma/vim-multiple-cursors'
Plugin 'pangloss/vim-javascript'
Plugin 'raimondi/delimitmate'
Plugin 'nathanaelkane/vim-indent-guides'
Plugin 'bling/vim-airline'
"Plugin 'scrooloose/syntastic'
Plugin 'bronson/vim-visual-star-search'
Plugin 'dracula/vim'
"Plugin 'MarcWeber/vim-addon-mw-utils'
"Plugin 'tomtom/tlib_vim'
"Plugin 'garbas/vim-snipmate'
Plugin 'KabbAmine/vCoolor.vim'
Plugin 'maksimr/vim-jsbeautify'
Plugin 'airblade/vim-gitgutter'
Plugin 'easymotion/vim-easymotion'
Plugin 'flazz/vim-colorschemes'
" Plugin 'jelera/vim-javascript-syntax'
Plugin 'danro/rename.vim'
Plugin 'posva/vim-vue'
"---gtpl-----------------------------------------------------------
call vundle#end() " required
filetype plugin indent on " required
" Alias Test
"----------------Random Configuration------------------"
"sessionoptions=blank,buffers,curdir,folds,help,options,tabpages,winsize
syntax enable "Enables syntax highlighting
set number "Enables line numbers
set smartindent
set clipboard=unnamed
if has('gui_running')
set background=dark
color dracula
else
let g:solarized_termcolors=256
set t_Co=256
set background=dark
color dracula
endif
if has("gui_macvim")
" For macvim specifically
set macligatures
endif
set guifont=Fira\ Code:h15
set foldcolumn=0
set guioptions-=e " Eliminates black bar at the top
"set showtabline=2
set backspace=indent,eol,start "Enables backspace functionality
let mapleader = ',' "Default leader is \ but , is better
set whichwrap+=<,>,h,l,[,]
set wrap
set linebreak
set expandtab
set tabstop=2
set shiftwidth=2
set nolist " list disables linebreak
let g:NERDTreeHijackNetrw=0 "Fixes NERDTREE opening on default
let g:netrw_banner = 0 "Eliminate NETRW banner on new window open
"----------------Visuals------------------"
"Disables scrollbars
set guioptions-=l
set guioptions-=L
set guioptions-=r
set guioptions-=R
" Transparent (Or Colored) Split Dividers
hi vertsplit guifg=bg guibg=bg
"----------------Search------------------"
set hlsearch
set incsearch
"----------------Split Management------------------"
set splitbelow
set splitright
map <Leader>1 :only<cr>
map <Leader>2 :vsp<cr>
map <Leader>3 :vsp<cr> :vsp<cr>
"Close current split
map <Leader>q :q!<cr>
"Equalize windows
map <Leader>= <c-w>=<cr>
map <Leader>- <c-w>_<cr>
"Add new split
map <Leader>+ :vsp <cr>
"Switch to previous window
map <Leader>` :b#<cr>
" Disable iSurround on Ctrl+S
imap <C-s> <nop>
" Makes it easier to navigate
nmap <C-J> <C-W><C-J>
nmap <C-K> <C-W><C-K>
nmap <C-H> <C-W><C-H>
nmap <C-L> <C-W><C-L>
"----------------Key Mappings (gtkm)------------------"
" Vim-specific General
nmap <Leader>ev :tabedit $MYVIMRC<cr>
nmap <Leader>es :tabedit ~/.vim/snippets/
" Session creation
nmap <Leader>ss :mks! ~/.vim/sessions/
nmap <Leader>ls :so ~/.vim/sessions/
nmap <Leader><space> :nohlsearch<cr>
" Indents
map <S-Tab> <<
"NERDTree + NERDCommenter
nmap <Leader>k :NERDTreeToggle<cr>
nmap <Leader>cc :VCoolor<cr>
" ColorPicker mapping
map <Leader>cp :VCoolor<cr>
" Intuitive navigation bindings
nnoremap k gk
nnoremap j gj
" Trigger CTRLP with Cmd
nmap <D-p> :CtrlP<cr>
map <Leader>p :CtrlP<cr>
" Emmet
"Allows for tab to expand snippets while still allowing tab functionality
imap <expr> <tab> emmet#expandAbbrIntelligent("\<tab>")
" Find and search next
map <C-n><D-d> <nop>
map <D-d> <C-n>
" Find tag
nmap <Leader>f :tag<space>
"----------------Auto Commands------------------"
"Automatically source Vimrc file on save.
augroup autosourcing
autocmd!
autocmd BufWritePost .vimrc source %
augroup END
" Emmet
let g:user_emmet_expandabbr_key = '<Tab>'
" NERDTree/NerdCommenter
" CtrlP Config + Mappings
if exists("g:ctrl_user_command") "Unbind random variable so that ignore works
unlet g:ctrlp_user_command
endif
let g:ctrlp_custom_ignore = {
\ 'dir': 'node_modules\|vendor'
\ }
let g:ctrlp_match_window = 'top,order:ttb,min:1,max:10,results:30'
" ALlows CtrlP root directory to be adjusted by nerdtree
let g:NERDTreeChDirMode = 2
let g:ctrlp_working_path_mode = 'rw'
" Indent Guides Config
let g:indent_guides_auto_colors = 1
" JsBeautify Config
map <c-f> :call JsBeautify()<cr>
" DelimitMate Config
let delimitMate_expand_cr=1
map <expr> <CR> pumvisible() ? "\<c-y>" : "<Plug>delimitMateCR"
imap <C-Return> <CR><CR><C-o>k<Tab>
" Ultisnips Config
" Trigger configuration. Do not use <tab> if you use https://github.com/Valloric/YouCompleteMe.
map <Leader>es <Plug>:UltiSnipsEdit<cr>
let g:UltiSnipsExpandTrigger="<c-Tab>"
let g:UltiSnipsJumpForwardTrigger="<c-b>"
let g:UltiSnipsJumpBackwardTrigger="<c-z>"
" vim-gitgutter config
set updatetime=250
" EasyMotion Config
"----------------Random Configuration------------------"
syntax on "Enables syntax highlighting
set number "Enables line numbers
set clipboard=unnamed
if has('gui_running')
set background=dark
colorscheme solarized
else
let g:solarized_termcolors=256
set t_Co=256
set background=dark
colorscheme solarized
endif
if has("gui_macvim")
" For macvim specifically
set macligatures
endif
set guifont=Fira_Code:h17
set foldcolumn=0
set guioptions-=e " Eliminates black bar at the top
"set showtabline=2
set backspace=indent,eol,start "Enables backspace functionality
let mapleader = ',' "Default leader is \ but , is better
set whichwrap+=<,>,h,l,[,]
set wrap
set linebreak
set expandtab
set tabstop=2
set shiftwidth=2
set nolist " list disables linebreak
"----------------Visuals------------------"
"Disables scrollbars
set guioptions-=l
set guioptions-=L
set guioptions-=r
set guioptions-=R
" Transparent (Or Colored) Split Dividers
hi vertsplit guifg=bg guibg=bg
"----------------Search------------------"
set hlsearch
set incsearch
"----------------Split Management------------------"
set splitbelow
set splitright
map <Leader>1 :only<cr>
map <Leader>2 :vsp<cr>
map <Leader>3 :vsp<cr> :vsp<cr>
"Close current split
map <Leader>q :q!<cr>
"Equalize windows
map <Leader>= <c-w>=<cr>
"Equalize windows
map <Leader>+ :vsp <cr>
" Makes it easier to navigate
nmap <C-J> <C-W><C-J>
nmap <C-K> <C-W><C-K>
nmap <C-H> <C-W><C-H>
nmap <C-L> <C-W><C-L>
"----------------Key Mappings (gtkm)------------------"
" Vim-specific General
nmap <Leader>ev :tabedit $MYVIMRC<cr>
nmap <Leader>es :tabedit ~/.vim/snippets/
nmap <Leader><space> :nohlsearch<cr>
" Indents
map <S-Tab> <<
"NERDTree + NERDCommenter
nmap <Leader>k :NERDTreeToggle<cr>
map <Leader>cc <Plug>NERDCommenterToggleComment<cr>
" Intuitive navigation bindings
nnoremap k gk
nnoremap j gj
" Trigger CTRLP with Cmd
map <D-p> :CtrlP<cr>
map <Leader>p :CtrlP<cr>
" Emmet
"Allows for tab to expand snippets while still allowing tab functionality
imap <expr> <tab> emmet#expandAbbrIntelligent("\<tab>")
" Find and search next
map <C-d> <C-n><cr>
" Find tag
nmap <Leader>f :tag<space>
"----------------Auto Commands------------------"
"Automatically source Vimrc file on save.
augroup autosourcing
autocmd!
autocmd BufWritePost .vimrc source %
augroup END
"----------------Vundle Stuff ------------------"
set nocompatible " be iMproved, required
filetype off " required
" set the runtime path to include Vundle and initialize
set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()
"call vundle#begin('~/some/path/here')
" gtpl - Go To Plugins
"-----------------------------------------------------------
" let Vundle manage Vundle, required
Plugin 'VundleVim/Vundle.vim'
Plugin 'tpope/vim-vinegar'
Plugin 'scrooloose/nerdtree'
Plugin 'tpope/vim-surround'
Plugin 'kien/ctrlp.vim'
Plugin 'scrooloose/nerdcommenter'
Plugin 'mattn/emmet-vim'
Plugin 'terryma/vim-multiple-cursors'
Plugin 'pangloss/vim-javascript'
Plugin 'raimondi/delimitmate'
Plugin 'nathanaelkane/vim-indent-guides'
Plugin 'bling/vim-airline'
"Plugin 'scrooloose/syntastic'
Plugin 'bronson/vim-visual-star-search'
Plugin 'altercation/vim-colors-solarized'
Plugin 'MarcWeber/vim-addon-mw-utils'
Plugin 'tomtom/tlib_vim'
Plugin 'garbas/vim-snipmate'
"-----------------------------------------------------------
call vundle#end() " required
filetype plugin indent on " required
" Emmet
let g:user_emmet_expandabbr_key = '<Tab>'
" NERDTree/NerdCommenter
" None so far
" CtrlP Config + Mappings
if exists("g:ctrl_user_command") "Unbind random variable so that ignore works
unlet g:ctrlp_user_command
endif
let g:ctrlp_custom_ignore = {
\ 'dir': 'node_modules\|vendor'
\ }
let g:ctrlp_match_window = 'top,order:ttb,min:1,max:10,results:30'
" ALlows CtrlP root directory to be adjusted by nerdtree
let g:NERDTreeChDirMode = 2
let g:ctrlp_working_path_mode = 'rw'
" Syntastic Config (Recommended Settings)
set statusline+=%#warningmsg#
set statusline+=%{SyntasticStatuslineFlag()}
set statusline+=%*
let g:syntastic_always_populate_loc_list = 1
let g:syntastic_auto_loc_list = 1
let g:syntastic_check_on_open = 1
let g:syntastic_check_on_wq = 0
" Indent Guides Config
let g:indent_guides_auto_colors = 1
" Snipmate Config
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment