-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.vimrc
executable file
·103 lines (85 loc) · 3.02 KB
/
.vimrc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
" SET VARS {{{
" ----------------------------------------------------------------
" BASIC SETTING {{{
" ----------------------------------------------------------------
syntax on " 構文ごとに色分け
set number " indicate line number
set tabstop=2 " tabサイズ
set expandtab " タブをスペースに展開しない (expandtab:展開する)
set shiftwidth=2
"set autoindent " インデントを現在行と同一化
set smartindent " 新しい行は自動インデント
set fileformat=unix " 改行コード
set fileformats=unix,dos
set hlsearch " highlight of searched result
set noswapfile " swapを作らない
set directory=~/.vim/tmp " swap files
"--------------------------------------------------------------------------
" neobundle
set nocompatible " Be iMproved
filetype off " Required!
if has('vim_starting')
set runtimepath+=~/.vim/bundle/neobundle.vim/
endif
call neobundle#begin(expand('~/.vim/bundle/'))
" Let NeoBundle manage NeoBundle
" Required:
NeoBundleFetch 'Shougo/neobundle.vim'
" My Bundles here:
" Refer to |:NeoBundle-examples|.
" Note: You don't set neobundle setting in .gvimrc!
NeoBundle 'Shougo/neocomplcache'
NeoBundle 'editorconfig/editorconfig-vim'
NeoBundle 'nanotech/jellybeans.vim'
NeoBundle 'tyru/open-browser.vim'
NeoBundle 'kannokanno/previm'
" scala用syntax highlight
NeoBundle 'derekwyatt/vim-scala'
" .slim
NeoBundle 'slim-template/vim-slim'
" .tsx
NeoBundle 'leafgarland/typescript-vim'
" インデントされないので入れた
" http://qiita.com/raamen/items/2d6aaf0bc98cb52e9a07
NeoBundle 'jason0x43/vim-js-indent'
NeoBundle 'thinca/vim-quickrun'
call neobundle#end()
au BufRead,BufNewFile,BufReadPre *.ts set filetype=typescript
autocmd FileType typescript setlocal sw=2 sts=2 ts=2 et
colorscheme jellybeans
" colorscheme morning
filetype plugin indent on " Required!
" Previm
let g:previm_open_cmd = ''
nnoremap [previm] <Nop>
nmap <Space>p [previm]
nnoremap <silent> [previm]o :<C-u>PrevimOpen<CR>
nnoremap <silent> [previm]r :call previm#refresh()<CR>
"
" Installation check.
if neobundle#exists_not_installed_bundles()
echomsg 'Not installed bundles : ' .
\ string(neobundle#get_not_installed_bundle_names())
echomsg 'Please execute ":NeoBundleInstall" command.'
"finish
endif
" COMMAND SETTING {{{
" ----------------------------------------------------------------
" hide highlight by search
noremap <esc><esc> :nohlsearch<CR><esc>
" }}}
" TAGS SETTING {{{
" ----------------------------------------------------------------
" }}}
" FUNCTION SETTING {{{
" ----------------------------------------------------------------
" }}}
" EACH FILE SETTING {{{
" ----------------------------------------------------------------
"autocmd BufWritePost *.php call PHPLint()
autocmd BufNewFile,BufRead *.twig set filetype=php
autocmd BufNewFile,BufRead *.{md,mdwn,mkd,mkdn,mark*} set filetype=markdown
autocmd BufNewFile,BufRead *.vue set filetype=html
" 空白削除
autocmd BufWritePre * :%s/\s\+$//e
" }}}