error while running “source .vimrc”

前端 未结 2 400
鱼传尺愫
鱼传尺愫 2020-11-27 23:10

i am having a simple vimrc file when i run \"source .vimrc\" in ubuntu I am getting the following error.

$ source .vimrc 
bash: .vimrc: line 3: syntax error          


        
相关标签:
2条回答
  • 2020-11-28 00:03

    I usually do :so $MYVIMRC

    Just type :so $MY[tab] and it will autocomplete for you.

    0 讨论(0)
  • 2020-11-28 00:05

    You tried to source your Vim configuration file from bash. Do it from Vim:

    $ vim
    :source /path/to/.vimrc
    

    If it's located at ~/.vimrc, Vim will source that file automatically.

    0 讨论(0)
提交回复
热议问题