Over the past couple of weeks, I’ve been busy working and publishing on a few new Laravel packages, which can be found here and here. There first being a logger package, and the second being one to stop destructive commands.
The logger package has a migration and a model that would save logs to the database to help with how things are tracked. The migration can be ran by using the php artisan migrate command and you can publish the model by running php artisan vendor:publish --tag=logging-model which will allow you to add more logs if needed.
The package to stop destructive commands will stop database related commands being run on a production environment, such as php artisan migrate:fresh, php artisan migrate rollback. It will check your .env file to see what your APP_ENV is set as and if it’s set as production, it’ll display a warning and not allow the command be ran; the display will be something like This 'migrate:fresh' command is disabled in this environment for safety.
