class Webgen::CLI::CommandParser
This is the command parser class used for handling the webgen command line interface.
After creating an instance, the parse
method can be used for parsing the command line arguments and executing the requested command.
Attributes
The website directory. Default: the value of the WEBGEN_WEBSITE environment variable or the current working directory.
Note: Only available after the website
method has been called (which is always the case when a command is executed).
The log level. Default: Logger::INFO
Specifies whether verbose output should be used.
Public Class Methods
Create a new CommandParser
class.
Public Instance Methods
Parse the command line arguments.
Once the website directory information is gathered, the Webgen::Website
is initialized to allow additional CLI
commands to be added by extensions.
Utility method for getting the Webgen::Website
object.
Returns a new website object (not an already created one) if force_new
is set to true
.