Show built version in phar

This commit is contained in:
Christopher Vagnetoft
2026-01-17 18:08:55 +01:00
parent e3022469e7
commit c05cc0c23a
2 changed files with 10 additions and 0 deletions

View File

@@ -21,6 +21,14 @@ $logger = new class extends AbstractLogger
}
};
if (file_exists(__DIR__."/../src/build.php")) {
$build = include(__DIR__."/../src/build.php");
define("APP_VERSION", $build['version']);
} else {
define("APP_VERSION", "Dev");
}
$daemon = (new NoccyLabs\Ntfi\NtfiDaemon())
->setLogger($logger)
->setConfigFile($configFile)