2

プラットフォーム - Mac OS - 10.8.5

これが私の .vimrc ファイルで、その後にエラーが続きます。*私の git リポジトリは正しく設定されています ----- * git config --global core.editor "vim" (これは私の .bashrc で設定されています) ** set -o vi (私の .bashrc で設定されています)

.vimrc ファイル

set nocompatible " be iMproved, required
filetype off " required

" set the runtime path to include Vundle and initialize
set rtp+=~/.vim/bundle/vundle/
call vundle#rc()
" alternatively, pass a path where Vundle should install plugins
"let path = '~/some/path/here'
"call vundle#rc(path)

" let Vundle manage Vundle, required
Plugin 'gmarik/vundle'

" The following are examples of different formats supported.
" Keep Plugin commands between here and filetype plugin indent on.
" scripts on GitHub repos
Plugin 'tpope/vim-fugitive'
Plugin 'altercation/vim-colors-solarized'
Plugin 'ervandew/supertab'
Plugin 'klen/python-mode'
Bundle 'vim-ipython'
" Plugin 'ivanov/vim-ipython'
" scripts from http://vim-scripts.org/vim/scripts.html
" Plugin 'L9'
" scripts not on GitHub
" Plugin 'git://git.wincent.com/command-t.git'
" git repos on your local machine (i.e. when working on your own plugin)
" Plugin 'file:///home/gmarik/path/to/plugin'
" ...

Bundle 'flazz/vim-colorschemes'

filetype plugin indent on " required
" To ignore plugin indent changes, instead use:
"filetype plugin on
"
" Brief help
" :PluginList - list configured plugins
" :PluginInstall(!) - install (update) plugins
" :PluginSearch(!) foo - search (or refresh cache first) for foo
" :PluginClean(!) - confirm (or auto-approve) removal of unused plugins
"
" see :h vundle for more details or wiki for FAQ
" NOTE: comments after Plugin commands are not allowed.
" Put your stuff after this line
"
" Size of a hard tabstop
set tabstop=8 expandtab shiftwidth=4 softtabstop=4

set foldmethod=indent
set foldnestmax=2
set foldlevel=99

" I prefer to fold code with spacebar
nnoremap za
vnoremap zf

set background=dark
colorscheme solarized

" Have supertab use usercompletion by default, for tke sake of ipython
let g:SuperTabDefaultCompletionType = "context"
i

私が得るエラー:


492: Not an editor command: ^M
line 6:
E117: Unknown function: vundle#rc
line 10:
E492: Not an editor command: ^M
line 12:
E492: Not an editor command: Plugin 'gmarik/vundle'^M
line 13:
E492: Not an editor command: ^M
line 17:
E492: Not an editor command: Plugin 'tpope/vim-fugitive'^M
line 18:
E492: Not an editor command: Plugin 'altercation/vim-colors-solarized'^M
line 19:
E492: Not an editor command: Plugin 'ervandew/supertab'^M
line 20:
E492: Not an editor command: Plugin 'klen/python-mode'^M
line 21:
E492: Not an editor command: Bundle 'vim-ipython'^M
line 30:
E492: Not an editor command: ^M
line 31:
E492: Not an editor command: Bundle 'flazz/vim-colorschemes'^M
line 32:
E492: Not an editor command: ^M
line 48:
E474: Invalid argument: softtabstop=4^M
line 49:
E492: Not an editor command: ^M
line 50:
E474: Invalid argument: foldmethod=indent^M
line 51:
E474: Invalid argument: foldnestmax=2^M
line 52:
E474: Invalid argument: foldlevel=99^M
line 53:
E492: Not an editor command: ^M
line 57:
E492: Not an editor command: ^M
line 58:
E474: Invalid argument: background=dark^M
line 59:
E185: Cannot find color scheme solarized^M
line 60:
E492: Not an editor command: ^M
line 62:
E15: Invalid expression: "context"^M
4

4 に答える 4

3

プラグイン「gmarik/bundle」

である必要があります

プラグイン「gmarik/Vundle.vim」

--

また、vundle がいくつかの変更を加えたことにも注意してください。たとえば、「バンドル」は「プラグイン」である必要があり、代わりに

vundle#rc() を呼び出す

今は

vundle#begin() を呼び出す

于 2014-07-31T16:26:44.630 に答える
2

行末が間違っています - あなたの .vimrc には Windows の行末があり、dos2unix のようなものを使って修正してください。

于 2014-04-11T14:30:00.430 に答える
1

Vundle を .vim/bundle ディレクトリにクローンしてください:

 $ git clone https://github.com/gmarik/vundle.git ~/.vim/bundle/vundle 
于 2014-04-11T14:55:05.097 に答える
1

バンドルの問題に違いないと思います。「/bundle」に多くのバンドルがインストールされている可能性があります

ディレクトリ、それらを削除して試してください:

sudo git clone https://github.com/gmarik/Vundle.vim.git ~/.vim/bundle/Vundle.vim
于 2014-10-09T03:38:26.530 に答える