Laravel Installer抛出错误

时间:2016-01-12 11:29:10

标签: laravel

调用bash命令时出现此错误 laravel新项目

  

php -r“copy('。env.example','。env');”   php artisan clear-compiled

Warning: require(/Users/Dale/Desktop/Outstanding Projects/project/bootstrap/../vendor/autoload.php): failed to open stream: No such file or directory in /Users/Dale/Desktop/Outstanding Projects/project/bootstrap/autoload.php on line 17

Fatal error: require(): Failed opening required '/Users/Dale/Desktop/Outstanding Projects/project/bootstrap/../vendor/autoload.php' (include_path='.:') in /Users/Dale/Desktop/Outstanding Projects/project/bootstrap/autoload.php on line 17
Script php artisan clear-compiled handling the post-install-cmd event returned with an error

之前有人遇到过这个问题。

1 个答案:

答案 0 :(得分:4)

我假设您使用composer来安装Laravel。

Laravel在autoload.php目录中找不到您的vendor文件。试试composer installcomposer dumpautoload。还要检查autoload.php是否在目录中。

autoload.php的路径应位于bootstrap/autoload.php文件中,检查您的系统路径是否正确。