From 3285e33454b1571c9e6a7955a4c7545e94d6b1dc Mon Sep 17 00:00:00 2001 From: Moshe Weitzman Date: Sun, 2 Jul 2023 07:51:26 -0600 Subject: [PATCH] --editor must have a value (#5683) --- src/Attributes/OptionsetGetEditor.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Attributes/OptionsetGetEditor.php b/src/Attributes/OptionsetGetEditor.php index 5fdf613c64..644cff776d 100644 --- a/src/Attributes/OptionsetGetEditor.php +++ b/src/Attributes/OptionsetGetEditor.php @@ -6,13 +6,14 @@ use Attribute; use Consolidation\AnnotatedCommand\Parser\CommandInfo; +use Drush\Commands\DrushCommands; #[Attribute(Attribute::TARGET_METHOD)] class OptionsetGetEditor { public static function handle(\ReflectionAttribute $attribute, CommandInfo $commandInfo) { - $commandInfo->addOption('editor', 'A string of bash which launches user\'s preferred text editor. Defaults to ${VISUAL-${EDITOR-vi}}.', [], ''); + $commandInfo->addOption('editor', 'A string of bash which launches user\'s preferred text editor. Defaults to ${VISUAL-${EDITOR-vi}}.', [], DrushCommands::REQ); $commandInfo->addOption('bg', 'Launch editor in background process.', [], false); } }