LoginSignup
5
5

More than 5 years have passed since last update.

ComposerコマンドからLaravelプロジェクトを作成した際のエラー

Last updated at Posted at 2015-03-13
$ composer create-project laravel/laravel --prefer-dist
Installing laravel/laravel (v5.0.1)
  - Installing laravel/laravel (v5.0.1)
    Loading from cache

Created project in .
Loading composer repositories with package information
Installing dependencies (including require-dev)



  [RuntimeException]                                                                                                                  
  Could not load package dragonrun1/phpspec in http://packagist.org: [UnexpectedValueException] Could not parse version constraint ^  
  1.0.1: Invalid version string "^1.0.1"                                                                                              






  [UnexpectedValueException]                                                  
  Could not parse version constraint ^1.0.1: Invalid version string "^1.0.1"  



create-project [-s|--stability="..."] [--prefer-source] [--prefer-dist] [--repository-url="..."] [--dev] [--no-dev] [--no-plugins] [--no-custom-installers] [--no-scripts] [--no-progress] [--keep-vcs] [--no-install] [package] [directory] [version]

ComposerコマンドからLaravelプロジェクトを作成した際
上記のようなエラーが出た。

composerが古いのが原因のよう
アップデートすると解決した。

$ composer selfupdate
Updating to version d57187446151ef84b28cb9f6b3ed38cc2cffc597.
    Downloading: 100%         
Use composer self-update --rollback to return to version 1.0.0-alpha9
$ composer update
5
5
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
5
5