Envbar is a simple package that will add a colored bar to the top of your pages to indicate the current environment and the current branch or release.
To install this package is very simple, you just need to install it with composer:
composer require --dev larakitdev/envbar
After installing, you need to publish the assets and the configuration file:
php artisan vendor:publish --provider="LaraKit\EnvBar\EnvBarServiceProvider" --tag="assets"
php artisan vendor:publish --provider="LaraKit\EnvBar\EnvBarServiceProvider" --tag="config"
To keep the assets up-to-date and avoid issues in future updates, you may add the envbar:publish
command to the
post-update-cmd
scripts in your application's composer.json
file:
{
"scripts": {
"post-update-cmd": [
"@php artisan envbar:publish --ansi"
]
}
}
The configuration file is located in config/envbar.php
. All the necessary instructions are in the file.