clean install

This commit is contained in:
2024-12-10 15:08:16 +01:00
commit e14eb2d8fd
31193 changed files with 3555714 additions and 0 deletions

View File

@@ -0,0 +1,28 @@
<?php
namespace Consolidation\AnnotatedCommand\Attributes;
use Attribute;
use Consolidation\AnnotatedCommand\Parser\CommandInfo;
#[Attribute(Attribute::TARGET_METHOD | Attribute::IS_REPEATABLE)]
class Usage
{
/**
* @param $name
* The example command.
* @param $description
* A one line description.
*/
public function __construct(
public string $name,
public ?string $description = null
) {
}
public static function handle(\ReflectionAttribute $attribute, CommandInfo $commandInfo)
{
$args = $attribute->getArguments();
$commandInfo->setExampleUsage($args['name'], @$args['description']);
}
}