@@ -182,10 +182,19 @@ private function processCommandLineOptions(array $argv){
182182 exit (0 );
183183 }
184184 if ($ cmd ->hasOption ("version " )){
185+ $ built = date ("r " ) . " (Source) " ;
186+ if (($ phar = \Phar::running (true )) !== "" ){
187+ $ phar = new \Phar ($ phar );
188+ $ built = date ("r " , $ phar ->getMetadata ()["creationDate " ]) . " (Phar) " ;
189+ }
190+
185191 Util::println (Framework::PROG_NAME . " " . Framework::PROG_VERSION .
186- " \"" . Framework::CODENAME . "\" [PHP " . PHP_VERSION . "] " );
187- Util::println (Framework::PROG_NAME . " API " . Framework::API_LEVEL );
192+ " \"" . Framework::CODENAME . "\" (API " . Framework::API_LEVEL . ") " );
193+ Util::println ("Built: " . $ built );
194+ Util::println ("Copyright (C) 2016-2018 iTX Technologies " );
188195 Util::println (str_repeat ("- " , 30 ));
196+ Util::println ("OS => " . PHP_OS_FAMILY . " " . php_uname ("r " ));
197+ Util::println ("PHP => " . PHP_VERSION );
189198 foreach (["curl " , "Phar " , "pthreads " , "yaml " , "swoole " ] as $ ext ){
190199 Util::println (Util::generateExtensionInfo ($ ext ));
191200 }
@@ -272,8 +281,11 @@ public function start(bool $useMainThreadTick = true, array $argv = []){
272281 self ::PROG_VERSION . TextFormat::GREEN . " [ " . self ::CODENAME . "] " );
273282 Logger::info (TextFormat::GOLD . "Licensed under GNU General Public License v3.0 " );
274283
275- $ this ->moduleManager = new ModuleManager ($ this ->classLoader ,
276- $ this ->properties ->modulePath , $ this ->properties ->moduleDataPath );
284+ //TODO: preload plugins before initialize
285+ if ($ this ->moduleManager === null ){
286+ $ this ->moduleManager = new ModuleManager ($ this ->classLoader ,
287+ $ this ->properties ->modulePath , $ this ->properties ->moduleDataPath );
288+ }
277289
278290 if (!\iTXTech \SimpleFramework \SINGLE_THREAD ){
279291 Logger::info ("Starting ConsoleReader... " );
0 commit comments