<?php
use Mall\Framework\Core\Config;
use Jobs\Model\MConsole;

//require_once __DIR__ . DIRECTORY_SEPARATOR . '..' . DIRECTORY_SEPARATOR . '..' . DIRECTORY_SEPARATOR .  'Mall' . DIRECTORY_SEPARATOR . 'Bootstrap.php';
require_once '..' . DIRECTORY_SEPARATOR .  'Mall' . DIRECTORY_SEPARATOR . 'Bootstrap.php';

// 加载项目全局变量
require_once dirname(__FILE__) .DS. '.ENV.php';


$configPath = __DIR__ . DS . 'Config' . DS . 'Config.php';

if (!file_exists($configPath)) {
    exit($configPath . 'config file is not found');
}

Config::load($configPath);
$config = Config::getInstance()->all();

$console = new MConsole($config);
$console->run();
//【影子:报错添加】
Swoole\Event::wait();