Skip to content

Instantly share code, notes, and snippets.

@ivikash
Last active December 17, 2019 09:14
Show Gist options
  • Save ivikash/052bdfa1f7de405b4f2cf8073e4ba615 to your computer and use it in GitHub Desktop.
Save ivikash/052bdfa1f7de405b4f2cf8073e4ba615 to your computer and use it in GitHub Desktop.
Configuration for ideavim used by IntelliJ editors like PyCharm, WebStorm etc
" =============================================================
" Map Leader
" =============================================================
imap ,. <Esc>
vmap ,. <Esc>
" =============================================================
" Bookmark
" =============================================================
map mm :action ToggleBookmark<CR>
map ma :action ShowBookmarks<CR>
" =============================================================
" Clipboard
" =============================================================
set clipboard=unnamedplus,unnamed
" =============================================================
" AceAction
" =============================================================
map f :action AceAction<CR>
map F :action AceTargetAction<CR>
" =============================================================
" Global Configuration
" =============================================================
set ignorecase
set smartcase
set norelativenumber
set showmode
set hlsearch
" =============================================================
" Window
" =============================================================
map <,>s :action SplitHorizontally<CR>
map <,>v :action SplitVertically<CR>
map <C-W><DOWN> :action VimWindowDown<CR>
map <C-W><LEFT> :action VimWindowLeft<CR>
map <C-W><RIGHT> :action VimWindowRight<CR>
map <C-W><UP> :action VimWindowUp<CR>
" =============================================================
" Editor control
" =============================================================
" Reload .ideavimrc
nnoremap <,>r :source ~/.ideavimrc<CR>
" Copy until the end of the line
nnoremap Y y$
" Previous / next word
nnoremap k #
nnoremap j *
nnoremap / :action Find<CR>
nnoremap U :action $Redo<CR>
nnoremap <Space>o :action GotoFile<CR>
nnoremap <Space>O :action GotoClass<CR>
nnoremap <,>c :nohls<cr>
nnoremap <,>c :nohls<cr>
nnoremap <Space>T :action Refactorings.QuickListPopupAction<CR>
@AlexPl292
Copy link

Hi! Since 0.54 version of IdeaVim all the :action Vim* mappings don't work anymore. Here are the details: https://youtrack.jetbrains.com/issue/VIM-1871#focus=streamItem-27-3864326.0-0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment