-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.vimrc
executable file
·141 lines (104 loc) · 2.89 KB
/
.vimrc
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
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
"
" Disable compatibiity with vi
set nocompatible
" Enable autodetection of file type
filetype on
" Load plugins for file
filetype plugin on
" Load an indent file for detected file type
filetype indent on
set showmode
set nohlsearch
set autoindent
set scrolloff=8
set relativenumber
set incsearch
set splitbelow
set noswapfile
set clipboard=unnamedplus
set laststatus=2
set ruler
set nobackup
set nowritebackup
set hidden
let g:coc_disable_startup_warning = 1
" Set tab with to 4 columns
set tabstop=4 softtabstop=4
" Use space characters instead of tabs
set expandtab
" Do not wrap lines
set nowrap
" Set smart indenttion
set smartindent
" Set shift width
set shiftwidth=4
" Turn on syntax highlighting
syntax on
" Show line numbers
set number
" AUTOCOMPLETION
" Enable autocompletion
set wildmenu
" Make wildmenu behave like bash completion
set wildmode=list:longest
" Ignore these files in autocomplete
set wildignore=*.docx,*.jpg,*.png,*.gif,*.pdf,*.pyc,*.exe,*.flv,*.img,*.xlsx,**/node_modules
if has('ide')
" global settings
set ideamarks
set ideaput
" mappings for jetbrains editors, such as intellij, android studio and
" pycharm
map gf <Action>(GotoFile)
map <leader>b <Action>(Switcher)
endif
" I just can shake the fillig of using vim in vscode sometimes
if has('code')
endif
" -----------------------------------------------------
" PLUGINS ----------------------------------------- {{{
call plug#begin('~/.vim/plugged')
Plug 'christoomey/vim-tmux-navigator'
Plug 'dense-analysis/ale'
Plug 'preservim/nerdtree'
Plug 'Exafunction/codeium.vim', { 'branch': 'main' }
Plug 'sheerun/vim-polyglot'
Plug 'junegunn/fzf', { 'do': { -> fzf#install() } }
Plug 'neoclide/coc.nvim', {'branch': 'release'}
Plug 'neoclide/coc-python', {'do': 'yarn install --frozen-lockfile'}
Plug 'neoclide/coc-tabnine', {'do': 'yarn install --frozen-lockfile'}
Plug 'neoclide/coc-yaml', {'do': 'yarn install --frozen-lockfile'}
Plug 'neoclide/coc-json', {'do': 'yarn install --frozen-lockfile'}
Plug 'davidhalter/jedi-vim'
Plug 'vim-test/vim-test'
call plug#end()
runtime coc-init.vim
" }}}
" MAPPINGS ---------------------------------------- {{{
" Mappings
nnoremap <Space> <Nop>
let mapleader=" "
inoremap jj <esc>
inoremap jk <esc>
vnoremap jk <esc>
xnoremap jk <esc>
inoremap <esc> <nop>
nnoremap <silent><C-f> <Cmd>!tmux neww tmux-sess-man<CR>
nmap <Leader><Leader> <Cmd>source %<CR>
nmap <silent><Leader>x <Cmd>!chmod +x %<CR>
nmap <Leader>pv <Cmd>Vex<CR>
nmap <leader>f :Rg<CR>
nnoremap <C-c> <Cmd>q<CR>
nnoremap <Leader>cb <Cmd>q!<CR>
nnoremap <Leader>w <Cmd>w<CR>
" Use system clipboards instead of Vim's built-in clipboard
nnoremap <Leader>y "+Y
vnoremap <Leader>y "+Y
nnoremap <Leader>d "_d
vnoremap <Leader>d "_d
nnoremap <Leader>p "+P
" }}}
" STATUS LINE ------------------------------------- {{{
" Status bar code goes here.
" }}}
"