9
2

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

Laravelでcomposer dump-autoloadすら通らなくなったら

Posted at

症状

# composer dump-autoload
Generating optimized autoload files> Illuminate\Foundation\ComposerScripts::postAutoloadDump
> @php artisan package:discover

In ProviderRepository.php line 208:
                                                             
  Class 'App\Providers\RepositoryServiceProvider' not found  
                                                             

Script @php artisan package:discover handling the post-autoload-dump event returned with error code 1

そもそもartisanのコマンドがほぼ通らなくなってると思う
php artisan package:discoverがエラーを出してる?っぽい
ServiceProvider作って別ブランチ切り替えたらこうなった。

解決方法

bootstrap/cache以下.gitignore以外の「config.php」「packages.php」「services.php」などを削除する

で、もう一回composer dump-autoloadすると通る。

9
2
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
9
2

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?