-
Notifications
You must be signed in to change notification settings - Fork 0
/
.ideavimrc
80 lines (73 loc) · 2.79 KB
/
.ideavimrc
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
let mapleader = "," " leader is comma
let localleader = "," " leader is comma
set tabstop=4 " number of visual spaces per TAB
set softtabstop=4 " number of spaces in tab when editing
set shiftwidth=4 " spaces in newline start
set expandtab " tabs are spaces
set number " show line numbers
set rnu " show relative line numbers
set showcmd " show command in bottom bar
set cursorline " highlight current line
set surround " use surround shortcuts
set commentary "vim-commentary
filetype indent on " load filetype-specific indent files
set wildmenu " visual autocomplete for command menu
set showmatch " highlight matching [{()}]
set timeoutlen=500 " timeout for key combinations
set so=5 " lines to cursor
set backspace=2 " make backspace work like most other apps
set incsearch " search as characters are entered
set hlsearch " highlight matches
set ignorecase " do case insensitive matching
set smartcase " do smart case matching
set hidden
set fillchars+=stl:\ ,stlnc:\
set laststatus=2
set clipboard=unnamedplus "X clipboard as unnamed
"press fd to exit insert mode
imap fd <Esc>
vmap fd <Esc>
"@see https://youtrack.jetbrains.com/issue/VIM-510 on expand selected region. Press `Ctrl-W` and `Ctrl-Shift-W` to increase and decrease selected region
noremap ,xm :action SearchEverywhere<CR>
noremap ,ci :action CommentByLineComment<CR>
noremap ,xs :action SaveAll<CR>
noremap ,aa :action $Copy<CR>
noremap ,zz :action $Paste<CR>
noremap ,yy :action PasteMultiple<CR>
noremap ,qq :action FindInPath<CR>
noremap ,ss :action Find<CR>
noremap ,fp :action CopyPaths<CR>
noremap ,xk :action CloseEdito<CR>
noremap ,rr :action RecentFiles<CR>
noremap ,kk :action GotoFile<CR>
noremap ,ii :action GotoSymbol<CR>
noremap ,gi :action GotoImplementation<CR>
noremap ,gd :action GotoDeclaration<CR>
noremap ,xz :action ActivateTerminalToolWindow<CR>
noremap ,tf :action ToggleFullScreen<CR>
noremap ,td :action ToggleDistractionFreeMode<CR>
noremap ,tp :action TogglePresentationMode<CR>
noremap ,jb :action Back<CR>
noremap ,sa :action Annotate<CR>
noremap ,1 :action GoToTab1<CR>
noremap ,2 :action GoToTab2<CR>
noremap ,3 :action GoToTab3<CR>
noremap ,4 :action GoToTab4<CR>
noremap ,5 :action GoToTab5<CR>
noremap ,6 :action GoToTab6<CR>
noremap ,7 :action GoToTab7<CR>
noremap ,8 :action GoToTab8<CR>
noremap ,9 :action GoToTab9<CR>
noremap ,0 :action GoToLastTab<CR>
" ideavim don't support numberic character in hotkey in 0.55
" it's fixed in 0.55.1
noremap ,x1 <C-W>o
noremap ,x2 :split<CR>
noremap ,x3 :vsplit<CR>
noremap ,x0 :q
" move window
noremap ,wh <C-W>h<CR>
noremap ,wl <C-W>l<CR>
noremap ,wj <C-W>j<CR>
noremap ,wk <C-W>k<CR>
noremap ,xx :action EditorSelectWord<CR>