Mirage
Mirage

Reputation: 31568

Where do I need to put file composer.json for composer to work with Symfony

I have installed composer from this link, but I still could not find where do I need to place the composer.json file.

Upvotes: 10

Views: 16645

Answers (4)

Yakhlaf Yassir
Yakhlaf Yassir

Reputation: 63

You could create a composer.json file by using the composer init command whilst in the directory you want it to be created in

composer init

or

path/to/composer.phar init

Upvotes: 0

SteveOfOz
SteveOfOz

Reputation: 11

You may need to create a file called 'composer.json' See this document "https://getcomposer.org/doc/00-intro.md#declaring-dependencies"

Upvotes: 1

Charly
Charly

Reputation: 446

I just found on other topic that you can use :

php composer.phar --working-dir=/home/user/folder/ update

Upvotes: 1

KingCrunch
KingCrunch

Reputation: 132071

In the root of your project. Because you mentioned symfony, just have a look at the composer.json from the symfony-standard edition

https://github.com/symfony/symfony-standard/

Or even better: Follow the official instructions and use symfony-standard as starting point for your project directly.

Start by visiting the Symfony2 download page at http://symfony.com/download. On this page, you'll see the Symfony Standard Edition, which is the main Symfony2 distribution.

You can forkt it directly from github.

Upvotes: 7

Related Questions