Updates to vim
* add vim-node * add vim-json
This commit is contained in:
@@ -45,3 +45,5 @@ Bundle 'terryma/vim-multiple-cursors'
|
|||||||
Bundle 'tpope/vim-repeat'
|
Bundle 'tpope/vim-repeat'
|
||||||
Bundle 'tonchis/to-github-vim'
|
Bundle 'tonchis/to-github-vim'
|
||||||
Bundle 'sotte/presenting.vim'
|
Bundle 'sotte/presenting.vim'
|
||||||
|
Bundle 'moll/vim-node'
|
||||||
|
Bundle 'elzr/vim-json'
|
||||||
|
|||||||
@@ -4,6 +4,9 @@ snippet def
|
|||||||
${1}
|
${1}
|
||||||
], function (${2}) {
|
], function (${2}) {
|
||||||
});
|
});
|
||||||
|
snippet dec
|
||||||
|
declare(${1}, {
|
||||||
|
});
|
||||||
snippet req
|
snippet req
|
||||||
require([
|
require([
|
||||||
${1}
|
${1}
|
||||||
@@ -20,6 +23,9 @@ snippet :f
|
|||||||
snippet fun
|
snippet fun
|
||||||
function ${1:name}(${2:args}) {
|
function ${1:name}(${2:args}) {
|
||||||
}
|
}
|
||||||
|
snippet iife
|
||||||
|
(function () {
|
||||||
|
})();
|
||||||
# log snippets
|
# log snippets
|
||||||
snippet log
|
snippet log
|
||||||
console.log(${1});
|
console.log(${1});
|
||||||
|
|||||||
@@ -76,9 +76,12 @@ if has("autocmd") && !exists("autocommands_loaded")
|
|||||||
autocmd BufWritePost .vimrc.local source %
|
autocmd BufWritePost .vimrc.local source %
|
||||||
" save all files on focus lost, ignoring warnings about untitled buffers
|
" save all files on focus lost, ignoring warnings about untitled buffers
|
||||||
autocmd FocusLost * silent! wa
|
autocmd FocusLost * silent! wa
|
||||||
autocmd BufNewFile,BufRead *.json set filetype=javascript
|
|
||||||
autocmd BufNewFile,BufRead *.ejs set filetype=html
|
autocmd BufNewFile,BufRead *.ejs set filetype=html
|
||||||
autocmd BufNewFile,BufRead *.ino set filetype=c
|
autocmd BufNewFile,BufRead *.ino set filetype=c
|
||||||
|
|
||||||
|
" make quickfix windows take all the lower section of the screen when there
|
||||||
|
" are multiple windows open
|
||||||
|
autocmd FileType qf wincmd J
|
||||||
endif
|
endif
|
||||||
|
|
||||||
" code folding settings
|
" code folding settings
|
||||||
@@ -142,6 +145,7 @@ set linebreak " set soft wrapping
|
|||||||
set showbreak=… " show ellipsis at breaking
|
set showbreak=… " show ellipsis at breaking
|
||||||
|
|
||||||
set autoindent " automatically set indent of new line
|
set autoindent " automatically set indent of new line
|
||||||
|
set smartindent
|
||||||
|
|
||||||
try
|
try
|
||||||
lang en_US
|
lang en_US
|
||||||
|
|||||||
Reference in New Issue
Block a user