Reputation: 2579
This question is mainly regarding yeoman
and composer create-project
command.
I am developing a yeoman generator for laravel5 and the issue I'm facing is that to install laravel, I need to run composer create-project
which creats a new folder called laravel
inside the root directory.
However, most yeoman packages generate the application in the root directory and all yeoman helpers work assuming that your files are in the root directory as well (for instance npmInstall looks for package.json at the root level).
Composer does not YET support creating a project in the same directory even if it was empty (https://github.com/composer/composer/issues/1135).
So I thought that I only have this solution:
composer create-project
in a temporary folder then move it's content back to the root folder and delete the temporary folder (node modules recommendations for that?)Is there any better way? If not, what are some node modules recommendations for moving the content of the folder up to the root directory (I had issues with that to make it cross platform).
I think this question should not be considered as too localized because it might help other yeoman contributors when working with composer.
Upvotes: 3
Views: 183
Reputation: 1414
Now composer
can create project in current directory if provided empty.
You can follow the detailed discussion over here on github
.
create project in same directory
With this you wont have to use any node module
to achieve file transfer.
Upvotes: 1