Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在尝试安装utilsnips。
当我输入:
cd ~/.vim/ git submodule add https://github.com/SirVer/ultisnips bundle/ultisnips
我收到这条消息:
You need to run this command from the toplevel of the working tree.
为什么?我怎样才能避免它?
您的.vim目录可能不是git目录。简单地使它成为一个git目录:
.vim
git
git init
然后你可以运行:
git submodule add https://github.com/SirVer/ultisnips bundle/ultisnips
您可能正在从子目录运行命令。确保您位于与 .git 目录相同级别的目录中。