我正在尝试将 c.vim 插件包含到我的 Vim 中。
不知何故,它无法识别,我将 mapleader 更改为,
并仍在使用\
我的数字,问题隐藏在我的 .vimrc 中的某个地方,所以我会附上它。
任何帮助将不胜感激!
"####################################################
" Basic Settings
"####################################################
"Set the Mapleader
let mapleader=","
"Setzt den Localleader
let localleader="-"
"Aktiviert Plugins
filetype plugin on
source ~/.vim/ftplugin/c.vim
"Neue Dateien werden beim erstellen gespeichert
autocmd BufNewFile * :write
"####################################################
" Various Settings
"####################################################
" Complete options (disable preview scratch window)
"set completeopt = menu, menuone, longest
" Limit popup menu height
"set pumheight = 15
" SuperTab option for context aware completion
let g:SuperTabDefaultCompletionType = "context"
" Disable auto popup, use <Tab> to autocomplete
let g:clang_complete_auto = 0
" Show clang errors in the quickfix window
let g:clang_complete_copen = 1
"Automatic VIMRC update when VIMRC is written
au! BufWritePost .vimrc source %
"####################################################
" Basic Maps
"#####################################################
"interpreting ii as <ESC>
inoremap ii <ESC>
"cnoremap jj <c-c>
",v opens .vimrc in a new window
noremap <leader>v :e $MYVIMRC<CR><C-W>
"Y yanks to the end of the line
nnoremap Y y$
"shorcut for copying line to clipboard
nnoremap <leader>y "*y
nnoremap <leader>p "*p
"word around the cursor is capitalized
inoremap <c-u> <ESC>BvWU<ESC>Ea
"H moves the cursor to the begining of the line, L to the end
nnoremap H 0
nnoremap L $
"LustyJuggler is activated with ,b
nnoremap <silent> <leader>b :LustyJuggler<CR>
"mark a word in visual mode
vnoremap <leader>a <ESC>bve
"#################################################
" C++ - Settings
"#################################################
"#################################################
" Various Settings
"################################################
"Spellcheking in German
set spelllang=de
set spellfile=~/.vim/spell.de.utf-8.add
nnoremap <leader>s :setlocal spell! spelllang=de
"Change the directory to the one of the current file
autocmd BufEnter * lcd %:p:h