1
0
Fork 0
mirror of synced 2024-06-26 02:31:09 -04:00
This commit is contained in:
Bjorn Johnson 2017-01-17 22:44:53 +00:00 committed by GitHub
commit d23c665a61
6 changed files with 51 additions and 44 deletions

@ -0,0 +1 @@
Subproject commit b7eee8428170eb280281ee1451a07a4bbb03e859

@ -0,0 +1 @@
Subproject commit 40ac6c462e2f76cb76d8a0f295abc358abc198bb

View file

@ -84,9 +84,9 @@ set wildmenu
" Ignore compiled files " Ignore compiled files
set wildignore=*.o,*~,*.pyc set wildignore=*.o,*~,*.pyc
if has("win16") || has("win32") if has("win16") || has("win32")
set wildignore+=.git\*,.hg\*,.svn\*
else
set wildignore+=*/.git/*,*/.hg/*,*/.svn/*,*/.DS_Store set wildignore+=*/.git/*,*/.hg/*,*/.svn/*,*/.DS_Store
else
set wildignore+=.git\*,.hg\*,.svn\*
endif endif
"Always show current position "Always show current position
@ -153,12 +153,15 @@ if $COLORTERM == 'gnome-terminal'
endif endif
try try
colorscheme desert colorscheme peaksea
catch catch
endtry endtry
set background=dark set background=dark
"jsx highlighting
let g:jsx_ext_required = 0
" Set extra options when running in GUI mode " Set extra options when running in GUI mode
if has("gui_running") if has("gui_running")
set guioptions-=T set guioptions-=T
@ -193,8 +196,8 @@ set expandtab
set smarttab set smarttab
" 1 tab == 4 spaces " 1 tab == 4 spaces
set shiftwidth=4 set shiftwidth=2
set tabstop=4 set tabstop=1
" Linebreak on 500 characters " Linebreak on 500 characters
set lbr set lbr
@ -217,6 +220,10 @@ vnoremap <silent> # :<C-u>call VisualSelection('', '')<CR>?<C-R>=@/<CR><CR>
""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" """""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" => Moving around, tabs, windows and buffers " => Moving around, tabs, windows and buffers
""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" """""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" Treat long lines as break lines (useful when moving around in them)
map j gj
map k gk
" Map <Space> to / (search) and Ctrl-<Space> to ? (backwards search) " Map <Space> to / (search) and Ctrl-<Space> to ? (backwards search)
map <space> / map <space> /
map <c-space> ? map <c-space> ?

View file

@ -21,15 +21,22 @@ elseif has("unix")
set gfn=Monospace\ 11 set gfn=Monospace\ 11
endif endif
" Open MacVim in fullscreen mode
if has("gui_macvim")
set fuoptions=maxvert,maxhorz
au GUIEnter * set fullscreen
endif
" Disable scrollbars (real hackers don't use scrollbars for navigation!) " Disable scrollbars (real hackers don't use scrollbars for navigation!)
set guioptions-=r set guioptions+=r
set guioptions-=R set guioptions-=R
set guioptions-=l set guioptions-=l
set guioptions-=L set guioptions-=L
set mouse=a
" Colorscheme " Colorscheme
set background=dark set background=dark
colorscheme peaksea colorscheme ir_black
""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" """""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
@ -78,6 +85,7 @@ imap ½ $
""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" """""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
cnoremap <C-E> <End>
" => Parenthesis/bracket " => Parenthesis/bracket
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" """"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
vnoremap $1 <esc>`>a)<esc>`<i(<esc> vnoremap $1 <esc>`>a)<esc>`<i(<esc>
@ -135,3 +143,12 @@ endfunc
func! CurrentFileDir(cmd) func! CurrentFileDir(cmd)
return a:cmd . " " . expand("%:p:h") . "/" return a:cmd . " " . expand("%:p:h") . "/"
endfunc endfunc
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" => BJORN BJORN BJORN
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
:imap jk <Esc>
:set relativenumber
:set number
let g:syntastic_javascript_checkers = ['eslint']

View file

@ -17,15 +17,12 @@ au FileType python map <buffer> <leader>1 /class
au FileType python map <buffer> <leader>2 /def au FileType python map <buffer> <leader>2 /def
au FileType python map <buffer> <leader>C ?class au FileType python map <buffer> <leader>C ?class
au FileType python map <buffer> <leader>D ?def au FileType python map <buffer> <leader>D ?def
au FileType python set cindent
au FileType python set cinkeys-=0#
au FileType python set indentkeys-=0#
"""""""""""""""""""""""""""""" """"""""""""""""""""""""""""""
" => JavaScript section " => JavaScript section
""""""""""""""""""""""""""""""" """""""""""""""""""""""""""""""
au FileType javascript call JavaScriptFold() "au FileType javascript call JavaScriptFold()
au FileType javascript setl fen au FileType javascript setl fen
au FileType javascript setl nocindent au FileType javascript setl nocindent
@ -35,33 +32,15 @@ au FileType javascript imap <c-a> alert();<esc>hi
au FileType javascript inoremap <buffer> $r return au FileType javascript inoremap <buffer> $r return
au FileType javascript inoremap <buffer> $f //--- PH<esc>FP2xi au FileType javascript inoremap <buffer> $f //--- PH<esc>FP2xi
function! JavaScriptFold() "function! JavaScriptFold()
setl foldmethod=syntax " setl foldmethod=syntax
setl foldlevelstart=1 " setl foldlevelstart=99
syn region foldBraces start=/{/ end=/}/ transparent fold keepend extend " syn region foldBraces start=/{/ end=/}/ transparent fold keepend extend
"
function! FoldText() " function! FoldText()
return substitute(getline(v:foldstart), '{.*', '{...}', '') " return substitute(getline(v:foldstart), '{.*', '{...}', '')
endfunction " endfunction
setl foldtext=FoldText() " setl foldtext=FoldText()
endfunction "endfunction
""""""""""""""""""""""""""""""
" => CoffeeScript section
"""""""""""""""""""""""""""""""
function! CoffeeScriptFold()
setl foldmethod=indent
setl foldlevelstart=1
endfunction
au FileType coffee call CoffeeScriptFold()
au FileType gitcommit call setpos('.', [0, 1, 1, 0])
""""""""""""""""""""""""""""""
" => Shell section
""""""""""""""""""""""""""""""
if exists('$TMUX')
set term=screen-256color
endif

View file

@ -73,11 +73,11 @@ set grepprg=/bin/grep\ -nH
""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" """""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" => Nerd Tree " => Nerd Tree
""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" """""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
let g:NERDTreeWinPos = "right" let g:NERDTreeWinPos = "left"
let NERDTreeShowHidden=0 let NERDTreeShowHidden=0
let NERDTreeIgnore = ['\.pyc$', '__pycache__'] let NERDTreeIgnore = ['\.pyc$', '__pycache__']
let g:NERDTreeWinSize=35 let g:NERDTreeWinSize=35
map <leader>nn :NERDTreeToggle<cr> map <leader>m :NERDTreeToggle<cr>
map <leader>nb :NERDTreeFromBookmark map <leader>nb :NERDTreeFromBookmark
map <leader>nf :NERDTreeFind<cr> map <leader>nf :NERDTreeFind<cr>
@ -85,8 +85,7 @@ map <leader>nf :NERDTreeFind<cr>
""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" """""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" => vim-multiple-cursors " => vim-multiple-cursors
""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" """""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
let g:multi_cursor_next_key="\<C-s>" let g:multi_cursor_next_key='<c-s>'
""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" """""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" => surround.vim config " => surround.vim config
@ -159,7 +158,10 @@ func! SyntasticCheckCoffeescript()
execute "SyntasticCheck" execute "SyntasticCheck"
execute "Errors" execute "Errors"
endfunc endfunc
nnoremap <silent> <leader>c :call SyntasticCheckCoffeescript()<cr> nnoremap <silent> <leader>l :call SyntasticCheckCoffeescript()<cr>
let g:syntastic_mode_map = {
\ "mode": "active",
\ "passive_filetypes": ["html"] }
""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" """""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""