Appends options related to the use of PKI utilities to a Commander-based
command.
@param {Command} command - The Commander command to append options
onto.
@returns {Command}
510258
function (command) {
    command.option('--opensslbin <file>',
      'Location of the OpenSSL executable that the command uses. If not ' +
      'specified, the command attempts to find an OpenSSL executable in ' +
      'the current environment path.')
    command.option('-s, --san [value]',
      'add Subject Alternative Name(s) to the CSR', sanOption, [])
    command.option('-P, --passphrase [pass]',
      'Password for the private key. If specified with no value, prompts ' +
      'for the value.')
    Object.keys(pki.SUBJECT_ATTRIBUTES).forEach(function (key) {
      var attributeInfo = pki.SUBJECT_ATTRIBUTES[key]
      var optionName = fieldAsOption(key)
      var optionValue = attributeInfo.optionValue || optionName.toLowerCase()
      command.option('--' + fieldAsOption(key) + ' <' + optionValue + '>',
        attributeInfo.description)
    })
    return command
  }
755015
function buildCommand(options, dir) {
  var cmd = options.bin;

  if (options.reportFile) {
    cmd += ' --log-pmd ' + options.reportFile;
  }

  cmd += ' --min-lines ' + options.minLines;
  cmd += ' --min-tokens ' + options.minTokens;

  if (options.exclude instanceof Array) {
    for (var i = 0, l = options.exclude; i < l; i++) {
      cmd += ' --exclude ' + options.exclude[i];
    }
  } else {
    cmd += ' --exclude ' + options.exclude;
  }

  cmd += ' --names \"' + options.names + '\"';

  if (options.namesExclude) {
    cmd += ' --names-exclude \"' + options.namesExclude + '\"';
  }

  if (options.quiet) {
    cmd += ' --quiet';
  }

  if (options.verbose) {
    cmd += ' --verbose';
  }

  return cmd + ' ' + dir;
}
413093
def add_command(self, cmd_name, *args):
        """"""
        self.__commands.append(Command(cmd_name, args))
31727
function appendRole (commandOptions, { accountId, roleName }) {
  return command(
    commandOptions,
    txHelper.addCommand(
      txHelper.emptyTransaction(),
      'appendRole',
      {
        accountId,
        roleName
      }
    )
  )
}
76744
function promiseCommand(command) {
    const opts = {
        env: process.env
    };
    console.log('>>>>', command)
    return spawnShell(command, opts).exitPromise
        .then((exitCode) => {
            if (exitCode === 0) {
                return;
            } else {
                throw Error("Exit " + exitCode)
            }
        })
}
1101098
function CommandAssignment(requisition) {
  var commandParamMetadata = {
    name: '__command',
    type: { name: 'command', allowNonExec: false }
  };
  // This is a hack so that rather than reply with a generic description of the
  // command assignment, we reply with the description of the assigned command,
  // (using a generic term if there is no assigned command)
  var self = this;
  Object.defineProperty(commandParamMetadata, 'description', {
    get: function() {
      var value = self.value;
      return value && value.description ?
          value.description :
          'The command to execute';
    },
    enumerable: true
  });
  this.param = new Parameter(requisition.system.types, commandParamMetadata);
}
1175462
def _add(self, command, *args, **kwargs):
        
        if self.indexable:
            self.index(args)
        return self._traverse_command(command, *args, **kwargs)
635176
function getKeyBindings(command) {
        var bindings    = [],
            commandID   = "";

        if (!command) {
            console.error("getKeyBindings(): missing required parameter: command");
            return [];
        }

        if (typeof (command) === "string") {
            commandID = command;
        } else {
            commandID = command.getID();
        }

        bindings = _commandMap[commandID];
        return bindings || [];
    }
774466
function prepare_command(input_args) {

  let command = null;
  const args = Array.prototype.slice.call(input_args);
  const funcOrCommand = args.shift();

  if (is(funcOrCommand, Command))
    command = funcOrCommand;

  if (is(funcOrCommand, Function))
    command = new Command(funcOrCommand);

  if (!command)
    throw new Error(Errors.BadExecuteArgument);

  command.arguments = args;
  command.result_file = null;

  return command;

}
499950
function Cli(argv) {
  var Cucumber = require('cucumber');
  var Command = require('commander').Command;
  var path = require('path');

  function collect(val, memo) {
    memo.push(val);
    return memo;
  }

  function getProgram() {
    var program = new Command(path.basename(argv[1]));

    program
      .usage('[options] [<DIR|FILE[:LINE]>...]')
      .version(Cucumber.VERSION, '-v, --version')
      .option('-b, --backtrace', 'show full backtrace for errors')
      .option('--compiler <EXTENSION:MODULE>', 'require files with the given EXTENSION after requiring MODULE (repeatable)', collect, [])
      .option('-d, --dry-run', 'invoke formatters without executing steps')
      .option('--fail-fast', 'abort the run on first failure')
      .option('-f, --format <TYPE[:PATH]>', 'specify the output format, optionally supply PATH to redirect formatter output (repeatable)', collect, ['pretty'])
      .option('--name <REGEXP>', 'only execute the scenarios with name matching the expression (repeatable)', collect, [])
      .option('--no-colors', 'disable colors in formatter output')
      .option('--no-snippets', 'hide step definition snippets for pending steps')
      .option('--no-source', 'hide source uris')
      .option('-p, --profile <NAME>', 'specify the profile to use (repeatable)', collect, [])
      .option('-r, --require <FILE|DIR>', 'require files before executing features (repeatable)', collect, [])
      .option('--snippet-syntax <FILE>', 'specify a custom snippet syntax')
      .option('-S, --strict', 'fail if there are any undefined or pending steps')
      .option('-t, --tags <EXPRESSION>', 'only execute the features or scenarios with tags matching the expression (repeatable)', collect, []);

    program.on('--help', function () {
      console.log('  For more details please visit https://github.com/cucumber/cucumber-js#cli\n');
    });

    return program;
  }

  function getConfiguration() {
    var program = getProgram();
    program.parse(argv);
    var profileArgs = Cucumber.Cli.ProfilesLoader.getArgs(program.profile);
    if (profileArgs.length > 0) {
      var fullArgs = argv.slice(0, 2).concat(profileArgs).concat(argv.slice(2));
      program = getProgram();
      program.parse(fullArgs);
    }
    var configuration = Cucumber.Cli.Configuration(program.opts(), program.args);
    return configuration;
  }

  var self = {
    run: function run(callback) {
      var configuration = getConfiguration();
      var runtime = Cucumber.Runtime(configuration);
      var formatters = [createIpcFormatter()].concat(configuration.getFormatters());
      formatters.forEach(function (formatter) {
        runtime.attachListener(formatter);
      });
      try {
        runtime.start(callback);
      } catch (e) {
        console.log(e.stack || e)
        callback(false)
      }
    }
  };
  return self;
}
355855
public void addCommand(Command pCommand) {
        if (!mCommands.containsKey(pCommand.getName())) {
            mCommands.put(pCommand.getName(), pCommand);
        }
    }
1360728
def enqueue_command(self, command_name, args, options):
        """"""
        assert_open(self)
        promise = Promise()
        self.commands.append((command_name, args, options, promise))
        return promise
677616
def add_command(command=nil,&block)
      command = Commands::Command.new(&block) if block_given?
      current_connection.add_command(command)
    end
493521
def add_command(self, command):
        
        self._commands.append(command)
        self._build_command_chain(command)
255522
function commandUsage(command, options, description) {
  return pkg.name + ' v' + pkg.version + ' - ' + description + 
  '\n\nUsage:\n  ' + pkg.name + ' ' + command + ' ' + options;
}
948793
function renderCommand(command) {

    if (!panel.buttonDiv) {
      var formGroup = addEle(panel.panelForm, 'div', 'form-group');
      panel.buttonDiv = addEle(formGroup, 'div', indent ? 'col-sm-offset-3 col-sm-9' : 'col-sm-9');
    }
    var cmdTheme = command.theme || 'default';
    var button = addEle(panel.buttonDiv, 'button', 'btn btn-' + cmdTheme + ' btn-presentation', {type: 'button'});

    var icon = command.icon;
    if (icon) {
      if (left(icon, 2) == 'fa')
        icon = '<i class="fa ' + icon + '"></i>&nbsp;';
      else
        icon = '<span class="glyphicon ' + icon + '"></span>&nbsp;';
      button.innerHTML = icon + command.name;
    } else {
      button.innerHTML = command.name;
    }

    $(button).on('click', function (event) {
      event.preventDefault();
      bootstrapInterface.dispatch(new Request({type: 'Command', command: command}));
    });
    panel.listeners.push(button); // so we can avoid leakage on deleting panel
  }
274410
function execList(options) {
  const deferred = Q.defer();

  const json = options.json !== false;
  const offline = options.offline !== false;
  const cwd = options.cwd || process.cwd();
  const config = {json, offline, cwd};

  bower.commands.list(undefined, config)
      .on('end', (conf) => {
        deferred.resolve(flatten(conf));
      })
      .on('error', (error) => {
        deferred.reject(error);
      });

  return deferred.promise;
}