This commit is contained in:
Gvidas Juknevičius 2024-08-25 23:48:10 +03:00
parent 85dac18494
commit dfa9e305ab
Signed by: MCorange
GPG Key ID: 12B1346D720B7FBB

View File

@ -13,6 +13,8 @@ end
rawset(__BUNDLER_FILES, "main", function ()
local updater = require("updater");
local log = require("log");
local notifier = require("notifier")
local json = require("json")
local MODULE_NAME = "keypadOS";
local MODULE_URL = "https://git.mcorangehq.xyz/xomf/keypadOS/raw/branch/keypad/keypadOS.lua";
if not __VERSION then
@ -28,7 +30,20 @@ rawset(__BUNDLER_FILES, "main", function ()
log.info("Starting bootloader (" .. __VERSION .. ")");
local upd = updater.new();
upd:addEntry(MODULE_NAME .. ".lua", "keypad", MODULE_URL);
parallel.waitForAny(function() updaterLoop(upd) end, require(MODULE_NAME))
local lib_exports = {
log = log,
updater = upd,
notifier = notifier,
json = json
};
parallel.waitForAny(
function()
updaterLoop(upd)
end,
function ()
require(MODULE_NAME)(lib_exports);
end
);
end
local mod = {};
mod.main = _start;