Last active
May 17, 2020 14:35
-
-
Save bitristan/c49e185e3c8e1037d96cacfd252755b1 to your computer and use it in GitHub Desktop.
Idea vim config.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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 | |
noremap ,ci :action CommentByLineComment | |
noremap ,xs :action SaveAll | |
noremap ,aa :action $Copy | |
noremap ,zz :action $Paste | |
noremap ,yy :action PasteMultiple | |
noremap ,qq :action FindInPath | |
noremap ,ss :action Find | |
noremap ,fp :action CopyPaths | |
noremap ,xk :action CloseEdito | |
noremap ,rr :action RecentFiles | |
noremap ,kk :action GotoFile | |
noremap ,ii :action GotoSymbol | |
noremap <C-]> :action GotoImplementation | |
noremap ,xz :action ActivateTerminalToolWindow | |
" 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 | |
noremap ,x3 :vsplit | |
noremap ,x0 :q | |
" move window | |
noremap ,wh <C-W>h | |
noremap ,wl <C-W>l | |
noremap ,wj <C-W>j | |
noremap ,wk <C-W>k | |
noremap ,xx :action EditorSelectWord |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment