1

I have followed a tutorial on Tuts plus called "Getting started with laravel 4". I have intalled cygwin and composer which works fine. When i try installing laravel using the following command:

$ composer create-project laravel/laravel laravel

i get the following message:

Installing laravel/laravel (v4.2.0)
Downloading: 100%

Created project in laravel


[InvalidArgumentException]
Composer could not find the config file: C:\ProgramData\ComposerSetup\bin
To initialize a project, please create a composer.json file as described in the 
http://getcomposer.org/ "Getting Started" section

I have tried looking at the Getting Started section but I am not sure what this file should contain in a laravel project?

3 Answers 3

2

Go to

control panel > search for system > view advance system setting > environment variables > under system variable, select composer and delete it > ok> ok.

I think this will solve your problem

Sign up to request clarification or add additional context in comments.

Comments

1

You must not create laravel project on your own.

You should go to directory in which you want laravel directory to be created (and laravel directory must not exist) and now you should run:

composer create-project laravel/laravel laravel

laravel directory will be created automatically

3 Comments

In cygwin I have navigated to /cygdrive/c/xampp/htdocs which is where i run: composer create-project laravel/laravel laravel. This also creates the laravel directory but when i navigate to: localhost/laravel/public there is errors so i think the installation went wrong
@user3170354 And it should work without a problem if you have no laravel directory inside /cygdrive/c/xampp/htdocs/ If you have you should remove it and run the command once again. It should work. If it's not, probably there is some problem with your installation
I have also tried that multiple times. However every time this produces the following errors. Warning: require(C:\xampp\htdocs\laravel\bootstrap/../vendor/autoload.php): failed to open stream: No such file or directory in C:\xampp\htdocs\laravel\bootstrap\autoload.php on line 17 Fatal error: require(): Failed opening required 'C:\xampp\htdocs\laravel\bootstrap/../vendor/autoload.php' (include_path='.;C:\xampp\php\PEAR') in C:\xampp\htdocs\laravel\bootstrap\autoload.php on line 17
0

I've tried this:

COMPOSER=composer.json composer create-project laravel/laravel c:/laravel --prefer-dist

founded on - Composer could not find the config file.

It works for me!

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.