public function __construct() { $this->console = new Console(80, ' '); $helpMessage = './pop ' . $this->console->colorize('show', Console::BOLD_YELLOW) . "\t\tShow current posts" . PHP_EOL; $helpMessage .= './pop ' . $this->console->colorize('delete', Console::BOLD_YELLOW) . "\tDelete a post" . PHP_EOL; $helpMessage .= './pop ' . $this->console->colorize('help', Console::BOLD_YELLOW) . "\t\tThis help screen"; $help = new Command('help'); $help->setHelp($helpMessage); $this->console->addCommand($help); }
public function __construct() { $this->console = new Console(160, ' '); $helpMessage = './spider ' . $this->console->colorize('help', Console::BOLD_YELLOW) . "\t\t\t\tDisplay this help screen." . PHP_EOL; $helpMessage .= './spider ' . $this->console->colorize('crawl', Console::BOLD_YELLOW) . " <url> [--dir=] [--tags=]\tCrawl the URL." . PHP_EOL . PHP_EOL; $helpMessage .= 'The optional [--dir=] parameter allows you to set the output directory for the results report.' . PHP_EOL; $helpMessage .= 'The optional [--tags=] parameter allows you to set additional tags to scan for in a comma-separated list.' . PHP_EOL . PHP_EOL; $helpMessage .= 'Example:' . PHP_EOL . PHP_EOL; $helpMessage .= '$ ./spider crawl http://www.mydomain.com/ --dir=seo-report --tags=b,u'; $help = new Command('help'); $help->setHelp($helpMessage); $this->console->addCommand($help); }