Composer - specify `composer.json` path

后端 未结 1 1063
抹茶落季
抹茶落季 2021-01-17 13:27

Is it possible to specify the path to the composer.json file using the cli commands? Even better, is it possible to user a file with a different name?

相关标签:
1条回答
  • 2021-01-17 13:49

    I would suggest you take a look at this: https://getcomposer.org/doc/03-cli.md#environment-variables

    COMPOSER

    By setting the COMPOSER env variable it is possible to set the filename of composer.json to something else.

    For example:

    COMPOSER=composer-other.json php composer.phar install

    The generated lock file will use the same name: composer-other.lock in this example.

    0 讨论(0)
提交回复
热议问题