Changeset View
Changeset View
Standalone View
Standalone View
stand/lua/menu.lua
Show First 20 Lines • Show All 52 Lines • ▼ Show 20 Lines | return str .. color.escapefg(color.RED) .. "off" .. | ||||
color.resetfg() | color.resetfg() | ||||
end | end | ||||
end | end | ||||
local function bootenvSet(env) | local function bootenvSet(env) | ||||
loader.setenv("vfs.root.mountfrom", env) | loader.setenv("vfs.root.mountfrom", env) | ||||
loader.setenv("currdev", env .. ":") | loader.setenv("currdev", env .. ":") | ||||
config.reload() | config.reload() | ||||
if loader.getenv("kernelname") ~= nil then | |||||
loader.perform("unload") | |||||
end | |||||
end | end | ||||
-- Module exports | -- Module exports | ||||
menu.handlers = { | menu.handlers = { | ||||
-- Menu handlers take the current menu and selected entry as parameters, | -- Menu handlers take the current menu and selected entry as parameters, | ||||
-- and should return a boolean indicating whether execution should | -- and should return a boolean indicating whether execution should | ||||
-- continue or not. The return value may be omitted if this entry should | -- continue or not. The return value may be omitted if this entry should | ||||
-- have no bearing on whether we continue or not, indicating that we | -- have no bearing on whether we continue or not, indicating that we | ||||
▲ Show 20 Lines • Show All 479 Lines • Show Last 20 Lines |