Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/master'
Browse files Browse the repository at this point in the history
  • Loading branch information
enzolutions committed Jul 19, 2017
2 parents ebf9ba8 + a4a8efb commit fed6be8
Show file tree
Hide file tree
Showing 14 changed files with 26 additions and 26 deletions.
2 changes: 1 addition & 1 deletion src/Command/Config/EditCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ protected function interact(InputInterface $input, OutputInterface $output)
if (!$configName) {
$configNames = $this->configFactory->listAll();
$configName = $io->choice(
'Choose a configuration',
$this->trans('commands.config.edit.messages.choose-configuration'),
$configNames
);

Expand Down
12 changes: 6 additions & 6 deletions src/Command/DevelDumperCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -50,11 +50,11 @@ protected function configure()
{
$this
->setName('devel:dumper')
->setDescription($this->trans('Change the devel dumper plugin'))
->setDescription($this->trans('commands.devel.dumper.messages.change-devel-dumper-plugin'))
->addArgument(
'dumper',
InputArgument::OPTIONAL,
$this->trans('Name of the devel dumper plugin')
$this->trans('commands.devel.dumper.messages.name-devel-dumper-plugin')
)->setAliases(['dd']);
}

Expand All @@ -65,7 +65,7 @@ protected function interact(InputInterface $input, OutputInterface $output)
{
$io = new DrupalStyle($input, $output);
if (!\Drupal::moduleHandler()->moduleExists('devel')) {
$io->error($this->trans('Devel must be installed'));
$io->error($this->trans('commands.devel.dumper.messages.devel-must-be-installed'));

return 1;
}
Expand All @@ -76,7 +76,7 @@ protected function interact(InputInterface $input, OutputInterface $output)
$dumpKeys = $this->getDumperKeys();

$dumper = $io->choice(
$this->trans('Select a Debug Dumper'),
$this->trans('commands.devel.dumper.messages.select-debug-dumper'),
$dumpKeys,
'kint', //Make kint the default for quick 'switchback'
false
Expand All @@ -97,7 +97,7 @@ protected function execute(InputInterface $input, OutputInterface $output)
$dumper = $input->getArgument('dumper');
$dumpKeys = $this->getDumperKeys();
if (!in_array($dumper, $dumpKeys)) {
$io->error($this->trans('Dumper does not exist'));
$io->error($this->trans('commands.devel.dumper.messages.dumper-not-exist'));

return 1;
}
Expand All @@ -108,7 +108,7 @@ protected function execute(InputInterface $input, OutputInterface $output)
$develSettings->set('devel_dumper', $dumper)->save();
$io->info(
sprintf(
$this->trans('Devel Dumper set to: %s'),
$this->trans('commands.devel.dumper.messages.devel-dumper-set'),
$configFactory->get('devel.settings')->get('devel_dumper')
)
);
Expand Down
2 changes: 1 addition & 1 deletion src/Command/Generate/HelpCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ protected function interact(InputInterface $input, OutputInterface $output)
if (!$description) {
$description = $io->ask(
$this->trans('commands.generate.module.questions.description'),
'My Awesome Module'
$this->trans('commands.generate.module.suggestions.my-awesome-module')
);
}
$input->setOption('description', $description);
Expand Down
2 changes: 1 addition & 1 deletion src/Command/Generate/ModuleCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -298,7 +298,7 @@ function ($modulePath) use ($drupalRoot, $machineName) {
if (!$description) {
$description = $io->ask(
$this->trans('commands.generate.module.questions.description'),
'My Awesome Module'
$this->trans('commands.generate.module.suggestions.my-awesome-module')
);
}
$input->setOption('description', $description);
Expand Down
2 changes: 1 addition & 1 deletion src/Command/Generate/PluginFieldCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -248,7 +248,7 @@ protected function interact(InputInterface $input, OutputInterface $output)
if (!$description) {
$description = $io->ask(
$this->trans('commands.generate.plugin.field.questions.type-description'),
'My Field Type'
$this->trans('commands.generate.plugin.field.suggestions.my-field-type')
);
$input->setOption('type-description', $description);
}
Expand Down
2 changes: 1 addition & 1 deletion src/Command/Generate/PluginFieldTypeCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,7 @@ protected function interact(InputInterface $input, OutputInterface $output)
if (!$description) {
$description = $io->ask(
$this->trans('commands.generate.plugin.fieldtype.questions.description'),
'My Field Type'
$this->trans('commands.generate.plugin.fieldtype.suggestions.my-field-type')
);
$input->setOption('description', $description);
}
Expand Down
2 changes: 1 addition & 1 deletion src/Command/Generate/PluginImageEffectCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ protected function interact(InputInterface $input, OutputInterface $output)
if (!$description) {
$description = $io->ask(
$this->trans('commands.generate.plugin.imageeffect.questions.description'),
'My Image Effect'
$this->trans('commands.generate.plugin.imageeffect.suggestions.my-image-effect')
);
$input->setOption('description', $description);
}
Expand Down
4 changes: 2 additions & 2 deletions src/Command/Generate/ProfileCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ function ($machine_name) use ($validators) {
if (!$description) {
$description = $io->ask(
$this->trans('commands.generate.profile.questions.description'),
'My Useful Profile'
$this->trans('commands.generate.profile.suggestions.my-useful-profile')
);
$input->setOption('description', $description);
}
Expand Down Expand Up @@ -253,7 +253,7 @@ function ($machine_name) use ($validators) {
) {
$distribution = $io->ask(
$this->trans('commands.generate.profile.options.distribution'),
'My Kick-ass Distribution'
$this->trans('commands.generate.profile.suggestions.my-kick-ass-distribution')
);
$input->setOption('distribution', $distribution);
}
Expand Down
4 changes: 2 additions & 2 deletions src/Command/Generate/ThemeCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -291,7 +291,7 @@ function ($theme_path) use ($drupalRoot, $machine_name) {
if (!$description) {
$description = $io->ask(
$this->trans('commands.generate.theme.questions.description'),
'My Awesome theme'
$this->trans('commands.generate.theme.suggestions.my-awesome-theme')
);
$input->setOption('description', $description);
}
Expand All @@ -300,7 +300,7 @@ function ($theme_path) use ($drupalRoot, $machine_name) {
if (!$package) {
$package = $io->ask(
$this->trans('commands.generate.theme.questions.package'),
'Other'
$this->trans('commands.generate.theme.suggestions.other')
);
$input->setOption('package', $package);
}
Expand Down
8 changes: 4 additions & 4 deletions src/Command/Shared/FormTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -93,27 +93,27 @@ public function formQuestion(DrupalStyle $io)
$size = null;
if (in_array($input_type, ['textfield', 'password', 'password_confirm'])) {
$maxlength = $io->ask(
'Maximum amount of characters',
$this->trans('commands.generate.form.questions.max-amount-characters'),
'64'
);

$size = $io->ask(
'Width of the textfield (in characters)',
$this->trans('commands.generate.form.questions.textfield-width-in-chars'),
'64'
);
}

if ($input_type == 'select') {
$size = $io->ask(
'Size of multiselect box (in lines)',
$this->trans('commands.generate.form.questions.multiselect-size-in-lines'),
'5'
);
}

$input_options = '';
if (in_array($input_type, ['checkboxes', 'radios', 'select'])) {
$input_options = $io->ask(
'Input options separated by comma'
$this->trans('commands.generate.form.questions.input-options')
);
}

Expand Down
2 changes: 1 addition & 1 deletion src/Command/Shared/MenuTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ public function menuQuestion(DrupalStyle $io, $className)

$menu_link_desc = $io->ask(
$menu_link_desc = $this->trans('commands.generate.form.options.menu-link-desc'),
'A description for the menu entry'
$menu_link_desc = $this->trans('commands.generate.form.suggestions.description-for-menu')
);
$menu_options['menu_link_title'] = $menu_link_title;
$menu_options['menu_parent'] = $menu_parent;
Expand Down
6 changes: 3 additions & 3 deletions src/Command/Shared/PermissionTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,15 +23,15 @@ public function permissionQuestion(DrupalStyle $output)
while (true) {
$permission = $output->ask(
$this->trans('commands.generate.permission.questions.permission'),
'access content'
$this->trans('commands.generate.permission.suggestions.access-content')
);
$title = $output->ask(
$this->trans('commands.generate.permission.questions.title'),
'Access content'
$this->trans('commands.generate.permission.suggestions.access-content')
);
$description = $output->ask(
$this->trans('commands.generate.permission.questions.description'),
'Allow access to my content'
$this->trans('commands.generate.permission.suggestions.allow-access-content')
);
$restrictAccess = $output->choiceNoList(
$this->trans('commands.generate.permission.questions.restrict-access'),
Expand Down
2 changes: 1 addition & 1 deletion src/Command/Site/InstallCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -321,7 +321,7 @@ function ($profile) {
if (!$siteName) {
$siteName = $io->ask(
$this->trans('commands.site.install.questions.site-name'),
'Drupal 8'
$this->trans('commands.site.install.suggestions.site-name')
);
$input->setOption('site-name', $siteName);
}
Expand Down
2 changes: 1 addition & 1 deletion src/Command/Theme/PathCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ protected function execute(InputInterface $input, OutputInterface $output)
if (!in_array($theme, $this->getThemeList())) {
$io->error(
sprintf(
'Invalid theme name: %s',
$this->trans('commands.theme.path.messages.invalid-theme-name'),
$theme
)
);
Expand Down

0 comments on commit fed6be8

Please sign in to comment.