-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.ideavimrc
120 lines (97 loc) · 2.53 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
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
set incsearch
set cursorline
set smartcase
let mapleader = "\<space>"
nmap <esc> :noh<cr>
" Key mapping
map <leader>w <Action>(SaveAll)
map <leader>q :q<cr>
map <leader>n :noh<cr>
"map <leader>N :set hlsearch<cr>
map <leader>e :NERDTree<cr>
map <leader>r <Action>(SelectInProjectView)
map <leader>f <Action>(ReformatCode)
"map <leader>f <Action>(ReformatWithPrettierAction)
map <C-W><C-R> <Action>(MoveEditorToOppositeTabGroup)
map <leader>b <Action>(RecentFiles)
map <leader><cr> <Action>(GotoFile)
map <leader>\ <Action>(RecentChangedFiles)
map <leader>a <Action>(ShowIntentionActions)
map <leader>o <Action>(GotoNextError)
map <leader>i <Action>(GotoPreviousError)
map <leader>] <Action>(FindInPath)
map <leader>R <Action>(RenameElement)
map <leader>p <Action>(ManageRecentProjects)
map <leader>I <Action>(VcsShowPrevChangeMarker)
map <leader>O <Action>(VcsShowNextChangeMarker)
map <leader>c <Action>(CommentByLineComment)
map <leader>C <Action>(CommentByBlockComment)
map <leader>` <Action>(Vcs.QuickListPopupAction)
map gi <Action>(ReSharperGotoImplementation)
map <leader>P <Action>(CopyReferencePopupGroup)
map [c <Action>(VcsShowPrevChangeMarker)
map ]c <Action>(VcsShowNextChangeMarker)
map zf <Action>(CollapseSelection)
" Delete without yanking to clipboard "
vnoremap <leader>d "_d
vnoremap <leader>D "_D
vnoremap <leader>s "_s
vnoremap <leader>S "_S
nnoremap <leader>d "_d
nnoremap <leader>D "_D
nnoremap <leader>s "_s
nnoremap <leader>S "_S
nnoremap x "_x
" Paste without copy the selected text to clipboard
xnoremap p "_dP
""" Idea specific settings ------------------
set ideajoin
set ideastatusicon=gray
set idearefactormode=keep
set showmode
""" Plugin
set NERDTree
set surround
set splitright
" Hide mode in the bottom e.g., -- INSERT --
set noshowmode
" Folding setting
set foldmethod=indent
set foldnestmax=10
set nofoldenable
set foldlevel=20
" Ignore case sensitive when search
set ignorecase
" Enable clipboard to copy from system
set clipboard=unnamedplus
" Hightlight all the search matches
set hlsearch
set encoding=utf8
" Flag to support indent
set expandtab
set tabstop=4
set shiftwidth=4
set autoindent
set smartindent
autocmd FileType javascript setlocal shiftwidth=2 softtabstop=2
" Using mouse
set mouse=a
" Show line number
set nu rnu
" Use vimrc
set nocompatible
" Show code syntax
syntax enable
" Set persisten undo
set undofile
set undodir=~/.config/nvim/undodir
set undolevels=1000
set undoreload=10000
" Set no backup
set nobackup
set nowritebackup
set nowb
set noswapfile
" Disable annoy sounds
set visualbell
set noerrorbells