$res = $this->parseParameters($parser);
$this->config->load();
+ setlocale(LC_TIME, $this->config->locale);
+ $this->handleCommands($res);
+
if (!$this->config->cfgFileExists) {
throw new \Exception(
"No config file found. Looked at the following places:\n"
);
}
- setlocale(LC_TIME, $this->config->locale);
- $this->handleCommands($res);
-
$source = $this->config->loadSource();
$arEvents = $source->getEvents(
$this->config->date,
'action' => 'StoreString'
)
);
+ $parser->addOption(
+ 'debug',
+ array(
+ 'long_name' => '--debug',
+ 'description' => 'Development helper (mail)',
+ 'action' => 'StoreTrue'
+ )
+ );
return $parser;
}
$this->config->daysNext = $result->options['daysNext'];
$this->config->daysPrev = $result->options['daysPrev'];
+ $this->config->debug = $result->options['debug'];
$this->config->renderer = $result->options['renderer'];
$this->config->stopOnEmpty = $result->options['stopOnEmpty'];
$this->config->setDate($result->options['date']);