git 切换分支,警告提示 不能删除vendor目录
假设当前分支是dev
执行git checkout master
提示如下,
warning: unable to rmdir vendor/monolog/monolog: Directory not empty
warning: unable to rmdir vendor/nesbot/carbon: Directory not empty
warning: unable to rmdir vendor/psr/log: Directory not empty
warning: unable to rmdir vendor/ramsey/uuid: Directory not empty
warning: unable to rmdir vendor/symfony/polyfill-mbstring: Directory not empty
warning: unable to rmdir vendor/symfony/translation: Directory not empty
Switched to branch 'master'
Your branch is behind 'origin/master' by 1 commit, and can be fast-forwarded.
(use "git pull" to update your local branch)
vendor目录,是composer生成的,在 master分支下是没有的。
ps:用sourcetree,在dev分支拉取代码,会提示fatal: No url found for submodule path 'vendor/monolog/monolog' in .gitmodules
我开始以为是子模块配置有问题,但是在项目根目录下,没有找到.gitmodules
,我自己也没有添加子模块。
谢谢~
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
已解决:https://segmentfault.com/a/11...