This method returns a new App::Cmd object. During initialization, command plugins will be loaded.

Valid arguments are:

no_commands_plugin - if true, the command list plugin is not added
no_help_plugin - if true, the help plugin is not added
no_version_plugin - if true, the version plugin is not added
plugin_search_path - The path to search for commands in. Defaults to
results of plugin_search_path method

If no_commands_plugin is not given, App::Cmd::Command::commands will be required, and it will be registered to handle all of its command names not handled by other plugins.

If no_help_plugin is not given, App::Cmd::Command::help will be required, and it will be registered to handle all of its command names not handled by other plugins. Note: "help" is the default command, so if you do not load the default help plugin, you should provide your own or override the default_command method.

If no_version_plugin is not given, App::Cmd::Command::version will be required to show the application's version with command --version. The version command is not included in the command list.

This method runs the application. If called the class, it will instantiate a new App::Cmd object to run.

It determines the requested command (generally by consuming the first command-line argument), finds the plugin to handle that command, parses the remaining arguments according to that plugin's rules, and runs the plugin.

It passes the contents of the global argument array (@ARGV) to "prepare_command", but @ARGV is not altered by running an App::Cmd.

If "prepare_args" is not changed and there are no arguments in @ARGV, this method is called and should return an arrayref to be used as the arguments to the program. By default, it returns an empty arrayref.

These methods return the name of the program invoked to run this application. This is determined by inspecting $0 when the App::Cmd object is instantiated, so it's probably correct, but doing weird things with App::Cmd could lead to weird values from these methods.

If the program was run like this:

knight!rjbs$ ~/bin/rpg dice 3d6

Then the methods return:

arg0 - rpg
full_arg0 - /Users/rjbs/bin/rpg

These values are captured when the App::Cmd object is created, so it is safe to assign to $0 later.

If this method returns true (which, by default, it does not), then any unambiguous abbreviation for a registered command name will be allowed as a means to use that command. For example, given the following commands:

reticulate
reload
rasterize

Then the user could use ret for reticulate or ra for rasterize and so on.