I moved my project from desk to another.
When I run php artisan
it does not work.
I tried to run composer update
, but it returns the error
Script @php artisan package:discover handling the post-autoload-dump event returned with error code 255
Do you have .env file in your new project?
I had same error message. When I add .env file, error is gone.
success message like this.
I hope this will help you.
maybe you have an error in the project code (for example, in routes or controller). This may be one of the reasons for this error.
In my project, the web.php file has a syntax error. I defined this when I started the php artisan command
I solved the problem this way: