diff --git a/README.md b/README.md index cad753d..5c161fb 100644 --- a/README.md +++ b/README.md @@ -14,6 +14,7 @@ - [driftingly/rector-laravel](https://github.com/driftingly/rector-laravel) - [livewire/flux-pro](https://fluxui.dev/) - [laravel/boost](https://github.com/laravel/boost) +- [laravel/pennant](https://github.com/laravel/pennant) - [laravel/pao](https://github.com/laravel/pao) - [nunomaduro/essentials](https://github.com/nunomaduro/essentials) diff --git a/app/Features/Inventory.php b/app/Features/Inventory.php new file mode 100644 index 0000000..e2f971c --- /dev/null +++ b/app/Features/Inventory.php @@ -0,0 +1,16 @@ + env('PENNANT_STORE', 'database'), + + /* + |-------------------------------------------------------------------------- + | Pennant Stores + |-------------------------------------------------------------------------- + | + | Here you may configure each of the stores that should be available to + | Pennant. These stores shall be used to store resolved feature flag + | values - you may configure as many as your application requires. + | + */ + + 'stores' => [ + + 'array' => [ + 'driver' => 'array', + ], + + 'database' => [ + 'driver' => 'database', + 'connection' => null, + 'table' => 'features', + ], + + ], +]; diff --git a/database/migrations/2026_05_22_195355_create_features_table.php b/database/migrations/2026_05_22_195355_create_features_table.php new file mode 100644 index 0000000..65688c5 --- /dev/null +++ b/database/migrations/2026_05_22_195355_create_features_table.php @@ -0,0 +1,26 @@ +id(); + $table->string('name'); + $table->string('scope'); + $table->text('value'); + $table->timestamps(); + + $table->unique(['name', 'scope']); + }); + } + + public function down(): void + { + Schema::dropIfExists('features'); + } +};