我试图让我的Laravel 4第一次在这里运行,在Windows XP环境中使用WampServer2。我已经启用了php_openssl.dll。
当我在Laravel根目录上发出“composer install”时,它会通过安装filp / whoops,然后安装doctrine来启动安装。问题发生在学说中:
D:\My Box Files\webdev\laravel4>composer install
Loading composer repositories with package information
Installing dependencies (including require-dev)
- Installing filp/whoops (1.0.7)
Downloading: 100%
- Installing doctrine/lexer (dev-master bc0e1f0)
Downloading: 100%
- Installing doctrine/annotations (v1.1.2)
Downloading: 100%
...
...
- Installing doctrine/dbal (dev-master fbce4b5)
Downloading: 100%
[UnexpectedValueException]
'D:\My Box Files\webdev\laravel4\vendor/doctrine/dbal/0385cd8ce14f51b82fc70
029e8890ac0' is not a zip archive.
任何人都知道为什么会这样?
答案 0 :(得分:0)
根据https://github.com/composer/composer/issues/1242,它可能是与网络相关或已损坏的缓存文件:
问题是Composer缓存(在我的情况下已损坏)文件和 因此,无论何时运行该命令,它都会重用这些损坏的文件。 它永远不会下载文件的新版本。解决方案是 删除缓存文件并重新运行该命令。缓存文件在 作曲家主目录: https://getcomposer.org/doc/03-cli.md#composer-home下的{。}} cache.files文件夹。
您可以使用config
命令查看作曲家缓存文件的确切位置:
composer config --list