magallanes/bin/mage

21 lines
524 B
Plaintext
Raw Normal View History

2016-12-31 07:52:25 +01:00
#!/usr/bin/env php
<?php
date_default_timezone_set('UTC');
2016-12-31 08:32:47 +01:00
if (file_exists(__DIR__ . '/../../../autoload.php')) {
require __DIR__ . '/../../../autoload.php';
} elseif (file_exists(__DIR__ . '/../vendor/autoload.php')) {
require __DIR__ . '/../vendor/autoload.php';
}
2016-12-31 07:52:25 +01:00
use Mage\MageApplication;
try {
2021-02-19 02:07:19 +01:00
$file = sprintf('%s/.mage.yml', getcwd());
2018-04-10 09:59:43 +02:00
$mage = new MageApplication($file);
$mage->run();
} catch (Exception $exception) {
printf('Error: %s' . PHP_EOL, $exception->getMessage());
exit(9);
}