Jos*_*ard 3 symfony composer-php symfony-2.1
我正在尝试使用composer将我的Symfony 2项目从2.1.4更新到2.1.7并php composer.phar update正常运行,在更新了一些依赖项后,我收到以下错误:
[RuntimeException]
Failed to clone http://github.com/fabpot/Twig-extensions via git, https
and http protocols, aborting.
- git://github.com/fabpot/Twig-extensions
fatal: Not a git repository (or any of the parent directories): .git
- https://github.com/fabpot/Twig-extensions
fatal: Not a git repository (or any of the parent directories): .git
- http://github.com/fabpot/Twig-extensions
fatal: Not a git repository (or any of the parent directories): .git
Run Code Online (Sandbox Code Playgroud)
我已经检查了URL并且可以确认它存在,我也能够在git clone没有任何问题的情况下使用相同的CLI.
奇怪的是,如果我php composer.phar update twig/extensions单独运行它似乎更新没有问题.
Sel*_*aek 16
如果您有一个旧的symfony副本与供应商一起安装为git repos但删除了git repos,则通常会发生这种情况.要修复它,您应该删除供应商目录,以便它们将从头开始重新安装为git克隆或zip存档,但不需要任何先前的假设.