From 254595ac6a462a47767d5af8679d018ee2931d3a Mon Sep 17 00:00:00 2001 From: Shift Date: Fri, 20 Feb 2026 16:14:19 +0000 Subject: [PATCH 1/5] Bump dependencies for Laravel 13 --- composer.json | 110 +++++++++++++++++++++++++------------------------- 1 file changed, 55 insertions(+), 55 deletions(-) diff --git a/composer.json b/composer.json index 6b19b33..f0732a1 100644 --- a/composer.json +++ b/composer.json @@ -1,59 +1,59 @@ { - "name": "dyrynda/laravel-model-uuid", - "description": "This package allows you to easily work with UUIDs in your Laravel models.", - "license": "MIT", - "keywords": [ - "eloquent", - "laravel", - "model", - "uuid" - ], - "authors": [ - { - "name": "Michael Dyrynda", - "email": "michael@dyrynda.com.au", - "homepage": "https://dyrynda.com.au" - } - ], - "require": { - "php": "^8.2", - "illuminate/container": "^12.0", - "illuminate/contracts": "^12.0", - "illuminate/database": "^12.0", - "illuminate/events": "^12.0", - "illuminate/support": "^12.0", - "ramsey/uuid": "^4.7", - "spatie/laravel-package-tools": "^1.19" - }, - "autoload": { - "psr-4": { - "Dyrynda\\Database\\Support\\": "src/" - } - }, - "require-dev": { - "laravel/legacy-factories": "^1.3", - "laravel/pint": "^1.20", - "orchestra/testbench": "^10.0", - "phpunit/phpunit": "^11.5.3" - }, - "autoload-dev": { - "psr-4": { - "Tests\\": "tests/" - } - }, - "minimum-stability": "dev", - "prefer-stable": true, - "config": { - "sort-packages": true - }, - "extra": { - "branch-alias": { - "dev-main": "8.x-dev" + "name": "dyrynda/laravel-model-uuid", + "description": "This package allows you to easily work with UUIDs in your Laravel models.", + "license": "MIT", + "keywords": [ + "eloquent", + "laravel", + "model", + "uuid" + ], + "authors": [ + { + "name": "Michael Dyrynda", + "email": "michael@dyrynda.com.au", + "homepage": "https://dyrynda.com.au" + } + ], + "require": { + "php": "^8.2", + "illuminate/container": "^12.0|^13.0", + "illuminate/contracts": "^12.0|^13.0", + "illuminate/database": "^12.0|^13.0", + "illuminate/events": "^12.0|^13.0", + "illuminate/support": "^12.0|^13.0", + "ramsey/uuid": "^4.7", + "spatie/laravel-package-tools": "^1.19" + }, + "autoload": { + "psr-4": { + "Dyrynda\\Database\\Support\\": "src/" + } + }, + "require-dev": { + "laravel/legacy-factories": "^1.3", + "laravel/pint": "^1.20", + "orchestra/testbench": "^10.0|^11.0", + "phpunit/phpunit": "^11.5.3|^12.5.12" + }, + "autoload-dev": { + "psr-4": { + "Tests\\": "tests/" + } + }, + "minimum-stability": "dev", + "prefer-stable": true, + "config": { + "sort-packages": true }, - "laravel": { - "providers": [ - "Dyrynda\\Database\\Support\\LaravelModelUuidServiceProvider" - ] + "extra": { + "branch-alias": { + "dev-main": "8.x-dev" + }, + "laravel": { + "providers": [ + "Dyrynda\\Database\\Support\\LaravelModelUuidServiceProvider" + ] + } } - } } From 054724c7a1e1908c694796fe1948640c642cd67c Mon Sep 17 00:00:00 2001 From: Shift Date: Fri, 20 Feb 2026 16:14:19 +0000 Subject: [PATCH 2/5] Update GitHub Actions for Laravel 13 --- .github/workflows/run-tests.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/run-tests.yml b/.github/workflows/run-tests.yml index 403ab66..5252831 100644 --- a/.github/workflows/run-tests.yml +++ b/.github/workflows/run-tests.yml @@ -14,7 +14,10 @@ jobs: fail-fast: true matrix: php: [8.4, 8.3, 8.2] - laravel: ['^12.0'] + laravel: [^12.0, ^13.0] + exclude: + - laravel: ^13.0 + php: 8.2 name: P${{ matrix.php }} - L${{ matrix.laravel }} From 7afe21d510069718891aec5bed749ecb26603300 Mon Sep 17 00:00:00 2001 From: Rob Van Keilegom Date: Wed, 18 Mar 2026 10:34:16 +0100 Subject: [PATCH 3/5] =?UTF-8?q?=E2=9C=A8=20Upgrade=20spatie/laravel-packag?= =?UTF-8?q?e-tools=20to=20support=20L13?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index f0732a1..460355f 100644 --- a/composer.json +++ b/composer.json @@ -23,7 +23,7 @@ "illuminate/events": "^12.0|^13.0", "illuminate/support": "^12.0|^13.0", "ramsey/uuid": "^4.7", - "spatie/laravel-package-tools": "^1.19" + "spatie/laravel-package-tools": "^1.39" }, "autoload": { "psr-4": { From 9f9cd0cf327d4bc936017509f2fc3a0687e37ad7 Mon Sep 17 00:00:00 2001 From: Rob Van Keilegom Date: Wed, 18 Mar 2026 10:39:50 +0100 Subject: [PATCH 4/5] =?UTF-8?q?=F0=9F=8E=A8=20Run=20pint=20--repair?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/Casts/EfficientUuid.php | 5 +++-- src/GeneratesUuid.php | 8 ++++---- src/LaravelModelUuidServiceProvider.php | 2 +- src/Rules/EfficientUuidExists.php | 3 ++- tests/Feature/EfficientUuidExistsRuleTest.php | 4 ++-- tests/database/factories/CommentFactory.php | 3 ++- tests/database/factories/PostFactory.php | 3 ++- 7 files changed, 16 insertions(+), 12 deletions(-) diff --git a/src/Casts/EfficientUuid.php b/src/Casts/EfficientUuid.php index bee0e70..6cd80b2 100644 --- a/src/Casts/EfficientUuid.php +++ b/src/Casts/EfficientUuid.php @@ -3,6 +3,7 @@ namespace Dyrynda\Database\Support\Casts; use Illuminate\Contracts\Database\Eloquent\CastsAttributes; +use Illuminate\Database\Eloquent\Model; use Ramsey\Uuid\Uuid; class EfficientUuid implements CastsAttributes @@ -10,7 +11,7 @@ class EfficientUuid implements CastsAttributes /** * Transform the attribute from the underlying model values. * - * @param \Illuminate\Database\Eloquent\Model $model + * @param Model $model * @param mixed $value * @return mixed */ @@ -26,7 +27,7 @@ public function get($model, string $key, $value, array $attributes) /** * Transform the attribute to its underlying model values. * - * @param \Illuminate\Database\Eloquent\Model $model + * @param Model $model * @param mixed $value * @return array */ diff --git a/src/GeneratesUuid.php b/src/GeneratesUuid.php index 3874b65..2491cca 100644 --- a/src/GeneratesUuid.php +++ b/src/GeneratesUuid.php @@ -119,7 +119,7 @@ public function resolveUuidVersion(): string /** * Scope queries to find by UUID. * - * @param \Illuminate\Database\Eloquent\Builder $query + * @param Builder $query * @param string|array $uuid * @param string $uuidColumn */ @@ -137,7 +137,7 @@ public function scopeWhereUuid($query, $uuid, $uuidColumn = null): Builder /** * Scope queries to find by UUID. * - * @param \Illuminate\Database\Eloquent\Builder $query + * @param Builder $query * @param string|array $uuid * @param string $uuidColumn */ @@ -155,7 +155,7 @@ public function scopeWhereNotUuid($query, $uuid, $uuidColumn = null): Builder /** * Convert a single UUID or array of UUIDs to bytes. * - * @param \Illuminate\Contracts\Support\Arrayable|array|string $uuid + * @param Arrayable|array|string $uuid */ protected function bytesFromUuid($uuid): array { @@ -173,7 +173,7 @@ protected function bytesFromUuid($uuid): array /** * Normalises a single or array of input UUIDs, filtering any invalid UUIDs. * - * @param \Illuminate\Contracts\Support\Arrayable|array|string $uuid + * @param Arrayable|array|string $uuid */ protected function normaliseUuids($uuid): array { diff --git a/src/LaravelModelUuidServiceProvider.php b/src/LaravelModelUuidServiceProvider.php index 014fb7b..5de3a00 100644 --- a/src/LaravelModelUuidServiceProvider.php +++ b/src/LaravelModelUuidServiceProvider.php @@ -35,7 +35,7 @@ public function packageRegistered() }); Blueprint::macro('efficientUuid', function ($column): ColumnDefinition { - /** @var \Illuminate\Database\Schema\Blueprint $this */ + /** @var Blueprint $this */ return $this->addColumn('efficientUuid', $column); }); } diff --git a/src/Rules/EfficientUuidExists.php b/src/Rules/EfficientUuidExists.php index 8d85617..2cc41a2 100644 --- a/src/Rules/EfficientUuidExists.php +++ b/src/Rules/EfficientUuidExists.php @@ -2,12 +2,13 @@ namespace Dyrynda\Database\Support\Rules; +use Dyrynda\Database\Support\GeneratesUuid; use Illuminate\Contracts\Validation\Rule; use Ramsey\Uuid\Uuid; class EfficientUuidExists implements Rule { - /** @var \Dyrynda\Database\Support\GeneratesUuid */ + /** @var GeneratesUuid */ protected $model; /** @var string */ diff --git a/tests/Feature/EfficientUuidExistsRuleTest.php b/tests/Feature/EfficientUuidExistsRuleTest.php index c62ed6b..8e1d8bf 100644 --- a/tests/Feature/EfficientUuidExistsRuleTest.php +++ b/tests/Feature/EfficientUuidExistsRuleTest.php @@ -13,7 +13,7 @@ class EfficientUuidExistsRuleTest extends TestCase #[Test] public function it_passes_valid_existing_uuid() { - /** @var \Tests\Fixtures\EfficientUuidPost $post */ + /** @var EfficientUuidPost $post */ $post = factory(EfficientUuidPost::class)->create(); $rule = new EfficientUuidExists(EfficientUuidPost::class, 'efficient_uuid'); @@ -44,7 +44,7 @@ public function it_fails_on_any_non_uuid_invalid_strings() #[Test] public function it_works_with_custom_uuid_column_name() { - /** @var \Tests\Fixtures\EfficientUuidPost $post */ + /** @var EfficientUuidPost $post */ $post = factory(EfficientUuidPost::class)->create(); $rule = new EfficientUuidExists(EfficientUuidPost::class, 'custom_efficient_uuid'); diff --git a/tests/database/factories/CommentFactory.php b/tests/database/factories/CommentFactory.php index 0ad46f0..4e4f9ed 100644 --- a/tests/database/factories/CommentFactory.php +++ b/tests/database/factories/CommentFactory.php @@ -1,8 +1,9 @@ Date: Wed, 18 Mar 2026 10:42:36 +0100 Subject: [PATCH 5/5] =?UTF-8?q?=E2=9C=85=20Add=20tests=20for=20php=208.5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/run-tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/run-tests.yml b/.github/workflows/run-tests.yml index 5252831..1bfd540 100644 --- a/.github/workflows/run-tests.yml +++ b/.github/workflows/run-tests.yml @@ -13,7 +13,7 @@ jobs: strategy: fail-fast: true matrix: - php: [8.4, 8.3, 8.2] + php: [8.5, 8.4, 8.3, 8.2] laravel: [^12.0, ^13.0] exclude: - laravel: ^13.0