Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. ExecCommand.php

function ExecCommand::configure

Return value

void

Overrides Command::configure

File

vendor/composer/composer/src/Composer/Command/ExecCommand.php, line 28

Class

ExecCommand
@author Davey Shafik <me@daveyshafik.com>

Namespace

Composer\Command

Code

protected function configure() {
    $this->setName('exec')
        ->setDescription('Executes a vendored binary/script')
        ->setDefinition([
        new InputOption('list', 'l', InputOption::VALUE_NONE),
        new InputArgument('binary', InputArgument::OPTIONAL, 'The binary to run, e.g. phpunit', null, function () {
            return $this->getBinaries(false);
        }),
        new InputArgument('args', InputArgument::IS_ARRAY | InputArgument::OPTIONAL, 'Arguments to pass to the binary. Use <info>--</info> to separate from composer arguments'),
    ])
        ->setHelp(<<<EOT
Executes a vendored binary/script.

Read more at https://getcomposer.org/doc/03-cli.md#exec
EOT
);
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal