This commit is contained in:
Kilian Hofmann
2021-06-01 19:55:55 +02:00
parent 052cbe3038
commit d8c489c714
328 changed files with 36645 additions and 0 deletions
@@ -0,0 +1,22 @@
<?php
namespace Nuwave\Lighthouse\Console;
use Illuminate\Console\GeneratorCommand;
abstract class LighthouseGeneratorCommand extends GeneratorCommand
{
/**
* Get the desired class name from the input.
*
* As a typical workflow would be to write the schema first and then copy-paste
* a field name to generate a class for it, we uppercase it so the user does
* not run into unnecessary errors. You're welcome.
*
* @return string
*/
protected function getNameInput(): string
{
return ucfirst(trim($this->argument('name')));
}
}