Laravel 5.5 does not create .env file

I installed laravel 5.4 several times. Now I am trying to install laravel 5.5 using the same command. And it does not work.

composer create-project --prefer-dist laravel/laravel blog dev-develop

It has no installation errors, only a lot of suggestions. But the key is not generated and the .env file is not created. When I try to make the php-artisan key: generate

/public_html/blog/.env): failed to open stream: No such file or directory
+4
source share
5 answers

The same problems turned out as the problem, because the composer was not updated, the composer decided to update it, you can run:

composer self-update

Or you can download the latest version there , then you can create the project again and the file .envwill be automatically created.

+5

- Laravel Installer Composer. :

  • , , composer global update, composer update . , .

  • , composer self-update, composer update . , .

, .

+1

: cp .env.example .env

0

, :

cp.env.example.env php-artisan:

But, as one of the answers suggests here, you should update your composer if you have an old version. To check the installed version, do this using the composer -v

0
source

I have this version

Composer version @package_branch_alias_version@ (1.0.0-beta2) 2016-03-27 16:00:34

When I run composer self-updating, I get

 [InvalidArgumentException]
 Command "self-update" is not defined.
0
source

Source: https://habr.com/ru/post/1685080/


All Articles