Skip to content

Commit

Permalink
PHP 8.3 Support Improvements (#10)
Browse files Browse the repository at this point in the history
* wip

Signed-off-by: Mior Muhammad Zaki <[email protected]>

* wip

Signed-off-by: Mior Muhammad Zaki <[email protected]>

* wip

Signed-off-by: Mior Muhammad Zaki <[email protected]>

* wip

Signed-off-by: Mior Muhammad Zaki <[email protected]>

* wip

Signed-off-by: Mior Muhammad Zaki <[email protected]>

* wip

Signed-off-by: Mior Muhammad Zaki <[email protected]>

* wip

Signed-off-by: Mior Muhammad Zaki <[email protected]>

* wip

Signed-off-by: Mior Muhammad Zaki <[email protected]>

* wip

Signed-off-by: Mior Muhammad Zaki <[email protected]>

* wip

Signed-off-by: Mior Muhammad Zaki <[email protected]>

---------

Signed-off-by: Mior Muhammad Zaki <[email protected]>
  • Loading branch information
crynobone authored Nov 24, 2023
1 parent bd4f154 commit 302465f
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 6 deletions.
13 changes: 7 additions & 6 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,12 @@
},
"require-dev": {
"laravel/pint": "^1.6",
"orchestra/testbench": "^8.13",
"laravel/framework": "^10.26",
"mockery/mockery": "^1.5.1",
"orchestra/testbench-core": "^8.15",
"phpstan/phpstan": "^1.10.6",
"phpunit/phpunit": "^10.1"
"phpunit/phpunit": "^10.1",
"symfony/yaml": "^6.2"
},
"conflict": {
"orchestra/canvas": "<8.11.0",
Expand All @@ -64,9 +67,8 @@
"@clear",
"@prepare"
],
"prepare": "@php vendor/bin/testbench package:discover --ansi",
"clear": "@php vendor/bin/testbench package:purge-skeleton --ansi",
"build": "@php vendor/bin/testbench workbench:build --ansi",
"prepare": "@php vendor/bin/testbench package:discover --ansi",
"lint": [
"@php vendor/bin/phpstan analyse",
"@php vendor/bin/pint"
Expand All @@ -79,6 +81,5 @@
"@test"
]
},
"prefer-stable": true,
"minimum-stability": "dev"
"minimum-stability": "stable"
}
8 changes: 8 additions & 0 deletions src/Commands/GeneratorCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ public function __construct(Filesystem $files)
*
* @throws \Illuminate\Contracts\Filesystem\FileNotFoundException
*/
#[\Override]
public function handle()
{
return $this->generateCode() ? self::SUCCESS : self::FAILURE;
Expand All @@ -46,6 +47,7 @@ public function handle()
* @param string $name
* @return string
*/
#[\Override]
protected function getPath($name)
{
return $this->getPathUsingCanvas($name);
Expand All @@ -56,6 +58,7 @@ protected function getPath($name)
*
* @return string
*/
#[\Override]
protected function qualifyModel(string $model)
{
return $this->qualifyModelUsingCanvas($model);
Expand All @@ -66,6 +69,7 @@ protected function qualifyModel(string $model)
*
* @return string
*/
#[\Override]
protected function rootNamespace()
{
return $this->rootNamespaceUsingCanvas();
Expand All @@ -76,6 +80,7 @@ protected function rootNamespace()
*
* @return string|null
*/
#[\Override]
protected function userProviderModel()
{
return $this->userProviderModelUsingCanvas();
Expand All @@ -86,6 +91,7 @@ protected function userProviderModel()
*
* @return string
*/
#[\Override]
protected function viewPath($path = '')
{
return $this->viewPathUsingCanvas($path);
Expand All @@ -96,6 +102,7 @@ protected function viewPath($path = '')
*
* @return array<int, string>
*/
#[\Override]
protected function possibleModels()
{
return $this->possibleModelsUsingCanvas();
Expand All @@ -106,6 +113,7 @@ protected function possibleModels()
*
* @return array<int, string>
*/
#[\Override]
protected function possibleEvents()
{
return $this->possibleEventsUsingCanvas();
Expand Down
3 changes: 3 additions & 0 deletions src/Commands/MigrationGeneratorCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ abstract class MigrationGeneratorCommand extends \Illuminate\Console\MigrationGe
*
* @return void
*/
#[\Override]
public function __construct(Filesystem $files, Composer $composer)
{
parent::__construct($files, $composer);
Expand All @@ -32,6 +33,7 @@ public function __construct(Filesystem $files, Composer $composer)
* @param string $table
* @return string
*/
#[\Override]
protected function createBaseMigration($table)
{
return $this->createBaseMigrationUsingCanvas($table);
Expand All @@ -43,6 +45,7 @@ protected function createBaseMigration($table)
* @param string $table
* @return bool
*/
#[\Override]
protected function migrationExists($table)
{
return $this->migrationExistsUsingCanvas($table);
Expand Down

0 comments on commit 302465f

Please sign in to comment.