douyiji3919 2014-08-08 16:04
浏览 98
已采纳

使用composer安装CakePHP 3.0时出错

I tried to install cakephp 3.0 running:

composer create-project -s dev cakephp/app cakedev

and also git cloning cakephp/app and then running composer update but I keep getting the same error:

Installing cakephp/cakephp (3.0.x-dev 0a2ff83)
    Cloning 0a2ff83156e5725b7e9339fb655e280ee70ce5aa
Executing command (CWD): git clone --no-checkout 'git://github.com/cakephp/cakephp.git' '/home/vagrant/www/cakedev/vendor/cakephp/cakephp' && cd '/home/vagrant/www/cakedev/vendor/cakephp/cakephp' && git remote add composer 'git://github.com/cakephp/cakephp.git' && git fetch composer
Failed: [Symfony\Component\Process\Exception\ProcessTimedOutException] The process "git clone --no-checkout 'git://github.com/cakephp/cakephp.git' '/home/vagrant/www/cakedev/vendor/cakephp/cakephp' && cd '/home/vagrant/www/cakedev/vendor/cakephp/cakephp' && git remote add composer 'git://github.com/cakephp/cakephp.git' && git fetch composer" exceeded the timeout of 300 seconds.
Failed to download cakephp/cakephp from source: The process "git clone --no-checkout 'git://github.com/cakephp/cakephp.git' '/home/vagrant/www/cakedev/vendor/cakephp/cakephp' && cd '/home/vagrant/www/cakedev/vendor/cakephp/cakephp' && git remote add composer 'git://github.com/cakephp/cakephp.git' && git fetch composer" exceeded the timeout of 300 seconds.
Now trying to download from dist
  - Installing cakephp/cakephp (3.0.x-dev 0a2ff83)

Failed: [RuntimeException] Could not delete /home/vagrant/www/cakedev/vendor/cakephp/cakephp/.git/objects/pack/tmp_pack_9VVOjS:

Reading ./composer.json
Loading config file ./composer.json



  [RuntimeException]

  Could not delete /home/vagrant/www/cakedev/vendor/cakephp/cakephp/.git/objects/pack/tmp_pack_9VVOjS:

enter image description here

I tried to run the commands using sudo and also get error.

Any ideas?

  • 写回答

2条回答 默认 最新

  • doujiyong7604 2014-08-08 18:39
    关注

    Remove composer cache in ~/.composer/cache/* and try to increase composer timeout with this methods

    Try with --prefer-dist option if not works try to increase composer timeout (default il 300)

    export COMPOSER_PROCESS_TIMEOUT=600
    php composer.phar install --prefer-dist
    
    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(1条)

报告相同问题?

悬赏问题

  • ¥15 如何让企业微信机器人实现消息汇总整合
  • ¥50 关于#ui#的问题:做yolov8的ui界面出现的问题
  • ¥15 如何用Python爬取各高校教师公开的教育和工作经历
  • ¥15 TLE9879QXA40 电机驱动
  • ¥20 对于工程问题的非线性数学模型进行线性化
  • ¥15 Mirare PLUS 进行密钥认证?(详解)
  • ¥15 物体双站RCS和其组成阵列后的双站RCS关系验证
  • ¥20 想用ollama做一个自己的AI数据库
  • ¥15 关于qualoth编辑及缝合服装领子的问题解决方案探寻
  • ¥15 请问怎么才能复现这样的图呀