-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathvimrc
More file actions
executable file
·66 lines (50 loc) · 1.18 KB
/
Copy pathvimrc
File metadata and controls
executable file
·66 lines (50 loc) · 1.18 KB
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
"incompatible with vi
set nocompatible
"netrw
let g:netrw_browse_split =0
let g:netrw_winsize = 25
let g:netrw_banner = 0
let g:netrw_altv = 1
let g:netrw_list_hide = &wildignore
syntax on
"line numbers on
set number
"tabs show as 2 spaces, rather then 8
set tabstop=2
set shiftwidth=2
set expandtab
"try to detect filetypes and load plugins for them
filetype on
filetype plugin on
filetype indent on
"reload files changed outside vim
set autoread
"utf-8 encoding
set encoding=utf-8
set fileencoding=utf-8
"enable matchit plugin, ships with vim
runtime macros/matchit.vim
"Backspace default updates
set backspace=indent,eol,start
"Keep abandoned buffers
set hidden
"unix line endings
set fileformat=unix
set fileformats=unix,dos
"Set swp to /tmp
"set dir=/tmp/swp
"windows clipboard copy
"yank, put with clipboard without requiring "*
let &clipboard = has('unnamedplus') ? 'unnamedplus' : 'unnamed'
" map c-x and c-v to work as they do in windows, only in insert mode
vm <c-x> "+x
vm <c-c> "+y
cno <c-v> <c-r>+
exe 'ino <script> <C-V>' paste#paste_cmd['i']
" save with ctrl+s
nmap <c-s> :w<CR>
imap <c-s> <Esc>:w<CR>a
"buftabline
set hidden
nnoremap <Tab> :bnext<CR>
nnoremap <S-Tab> :bprev<CR>