m-j-smith / laravel-ci-config
A minimal GitHub Actions CI setup for Laravel projects.
v1.0.0
2026-06-01 20:56 UTC
Requires
- php: ^8.2
- illuminate/contracts: ^12.0|^13.0
README
A minimal GitHub Actions CI setup for Laravel projects.
What's included
-
Test runner via
php artisan testusing SQLite in-memory database (MySQL service not required). Compatible with both Pest and PHPUnit. -
Laravel Pint code style check using the
laravelpreset. -
Separate jobs so tests and style report independently.
Required Project Config
- PHP 8.2+
- Laravel 12+
.env.example
Ensure your .env.example includes:
APP_KEY= DB_CONNECTION=sqlite DB_DATABASE=:memory:
phpunit.xml
Ensure the following are uncommented in the <php> section:
<env name="DB_CONNECTION" value="sqlite"/> <env name="DB_DATABASE" value=":memory:"/>
Installation
- Install the package via Composer into your development dependencies:
composer require m-j-smith/laravel-ci-config --dev
- Install the GitHub Actions CI workflow and Pint config into your project:
php artisan ci:install
This will add the following files to your project:
.github/
└── workflows/
└── ci.yml
pint.json