zfi

If I may bump this issue, I have encountered the same set of circumstances.

I have a fresh installation of macOS 10.12.2; Installed both laravel/installer and laravel/valet. The composer.phar is installed in the /usr/local/bin/directory. I have created an alias to run composer.

composer is aliased to `php /usr/local/bin/composer.phar'

Running

laravel new blog

generates this response

Crafting application...
sh: composer: command not found
Application ready! Build something amazing.

The site does not run. In order to get the site to work, I had to run these additional steps:

cd blog
composer install —no-scripts
cp .env.example .env
php artisan key:generate

If I create the site using composer, the site works as expected.

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

I am fairly certain that the error from composer: command not found is where .env file is created and keyed. It is also where the dependancies are installed. Does anyone have thoughts on where to begin to troubleshoot this?

Return to Thread...