.ideavimrc

김민규·2023년 7월 6일
0

intelliJ

목록 보기
2/2
post-thumbnail
""" Map leader to space ---------------------
let mapleader = " "

""" Plugins  --------------------------------
Plug 'tpope/vim-surround'
Plug 'tpope/vim-commentary'
Plug 'terryma/vim-multiple-cursors'
" Plug 'vim-scripts/argtextobj.vim'
Plug 'tommcdo/vim-exchange'
Plug 'kana/vim-textobj-entire'
Plug 'vim-scripts/ReplaceWithRegister'
Plug 'machakann/vim-highlightedyank'
Plug 'preservim/nerdtree'

""" Plugin settings -------------------------
" let g:argtextobj_pairs="[:],(:),<:>"
let g:highlightedyank_highlight_duration=1000

let g:NERDTreeMapActivateNode='l'
let g:NERDTreeMapJumpParent='h'

" <C-n> seems to me as a better solution than <M-n>,
" but we should finally support vim-visual-multi because vim-multiple-cursors is deprecated now
map <C-n> <Plug>NextWholeOccurrence

""" Common settings -------------------------
" set showmode
set scrolloff=15
set incsearch
set number
set visualbell
set ignorecase
set smartcase
" set hlsearch
set noerrorbells
" set matchpairs+=a:b

""" Idea specific settings ------------------
set ideajoin
set ideastatusicon=gray
set idearefactormode=keep
" set ideastrictmode

nnoremap <SPACE> <Nop>

""" actions -----------------------
map <leader>gt <Action>(GotoTest)
map <leader>a <Action>(Annotate)
map <leader>z <Action>(ToggleDistractionFreeMode)
map <leader>o <Action>(FileStructurePopup)
map <leader>s <Action>(SelectInProjectView)
map <leader>h <action>(PreviousTab)
map <leader>l <action>(NextTab)
map <leader>bd <action>(CloseEditor)
map <leader>i <action>(Generate)
map <leader>m <action>(Git.Menu)
map <leader>/ <action>(ShowErrorDescription)
map <leader>gh <action>(gith)
"map <leader>rc <action>(RunConfiguration)
"map <leader>rr <action>(Run)

nnoremap <leader><leader> <C-Tab>

""" Tool -----------------------------
nnoremap [e :action GotoNextError<cr>
nnoremap ]e :action GotoPreviousError<cr>

map \r <Action>(Run)
map \t <Action>(RunClass)
map \d <Action>(Debug)
map \c <Action>(Stop)
map \b <Action>(ToggleLineBreakpoint)
map \f :NERDTreeFind

" Toggle case and start typing. E.g. `<leader>iget`: `property` -> `getProperty`
map <leader>i ~hi
" Remove selection and toggle case. E.g. `v2l<leader>u`: `getProperty` -> `property`
vmap <leader>u d~h
profile
Backend Engineer, Vim User

0개의 댓글