function args(name, settings)
{
    settings = extend(
        {
            'name':           name,
            'version':        '0.0.0',
            'version_string': '${name} ${version}',
            'default_action': function() {}
        },
        settings
    );

    command.call(this, name, null, settings);

    // add implicit --version option
    var me = this;

    command.prototype.addOption.call(this, 'version', '--version', true, {
        'help': 'Print version info.'
    }).setAction(function() {
        me.printVersion();
    });
    command.prototype.addOption.call(this, 'help', '-h | --help', true, {
        'help': 'Print help information.'
    }).setAction(function() {
        me.printHelp();
    });
}
/**
 * Constructor.
 *
 * @param   string          name            Name of application.
 * @param   object          settings        Optional settings.
 */
Constructor.
@param   string          name            Name of application.
@param   object          settings        Optional settings.
Constructor . @param string name Name of application . @param object settings Optional settings .
function args(name, settings)
{
    settings = extend(
        {
            'name':           name,
            'version':        '0.0.0',
            'version_string': '${name} ${version}',
            'default_action': function() {}
        },
        settings
    );
    command.call(this, name, null, settings);
    var me = this;
    command.prototype.addOption.call(this, 'version', '--version', true, {
        'help': 'Print version info.'
    }).setAction(function() {
        me.printVersion();
    });
    command.prototype.addOption.call(this, 'help', '-h | --help', true, {
        'help': 'Print help information.'
    }).setAction(function() {
        me.printHelp();
    });
}
function args ( name , settings ) { settings = extend ( { 'name' : name , 'version' : '0.0.0' , 'version_string' : '${name} ${version}' , 'default_action' : function ( ) { } } , settings ) ; command . call ( this , name , null , settings ) ; var me = this ; command . prototype . addOption . call ( this , 'version' , '--version' , true , { 'help' : 'Print version info.' } ) . setAction ( function ( ) { me . printVersion ( ) ; } ) ; command . prototype . addOption . call ( this , 'help' , '-h | --help' , true , { 'help' : 'Print help information.' } ) . setAction ( function ( ) { me . printHelp ( ) ; } ) ; }
Constructor.
Constructor .
// add implicit --version option