Skip to content

Publish Bugsnag's Laravel Configuration Only

Nov 14, 2021 1 min read #laravel #php

This post is more than 18 months old. Technology changes quickly, so some of this content may be out of date (but that's not always the case). Please verify any technical or programming information against the current release.

If you follow the instructions to customize the configuration of Bugsnag’s Laravel package, they’ll tell you to run vendor:publish. But this is not what I want.

This may actually publish more things than just their package’s details.

Instead, you can easily limit this to their configuration only by targeting their service provider with the following command:

php artisan vendor:publish --provider="Bugsnag\BugsnagLaravel\BugsnagServiceProvider"
bash

Now, it will only publish the config/bugnsag.php file.

Looking for more Laravel Tips & Tricks? Join Joel and I on the No Compromises bi-weekly podcast; around 15 minutes of thoughtful real-world advice and helpful info.