-
Notifications
You must be signed in to change notification settings - Fork 12
/
Copy pathxvimrc
72 lines (54 loc) · 1.29 KB
/
xvimrc
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
"
" A configuration file for https://github.com/JugglerShu/XVim
"
"
" Comments
nnoremap gcc :xcmenucmd Comment Selection<CR>
vnoremap gc :xcmenucmd Comment Selection<CR>
" Emulate CTRL-P
noremap <C-p> :xccmd openQuickly<CR>
" Case-insensitive searching.
set ignorecase
" But case-sensitive if expression contains a capital letter.
set smartcase
set hlsearch
nnoremap <Space>4 /~<CR>
" Setup the number line
set number
" Use the system pasteboard
set clipboard=unnamed
" noremap <space>b to toggle a breakpoint at the current line
nnoremap ,b :xccmd toggleBreakpointAtCurrentLine<CR>
" Better navigation
nnoremap H ^
nnoremap L $
" Window navigation
nnoremap <C-j> <C-w>j
nnoremap <C-k> <C-w>k
nnoremap <C-h> <C-w>h
nnoremap <C-l> <C-w>l
" Tab noremappings
nnoremap ,tt :xccmd newTab<CR>
nnoremap ,tc :tabclose<CR>
" Make computers make sense
nnoremap Y y$
" I'd like the following command to save too
" it doesn't seem like xvim supports this: \| update<CR>
vnoremap s :sort ui<CR>
" vim-unimpared knock off
nnoremap ]e "udd"up
nnoremap [e "uddk"uP
" Center after find
nnoremap n nzz
nnoremap N Nzz
" Change the background color for searches
highlight Search guibg=orange
" Better move controls
nnoremap j gj
nnoremap k gk
nnoremap gj j
nnoremap gk k
vnoremap j gj
vnoremap k gk
vnoremap gj j
vnoremap gk k