local function lib_load(path, name) if not _G[name] then os.loadAPI(fs.combine(path, "lib/" .. name .. ".lua")) if not _G[name] then _G[name] = _G[name .. ".lua"] end end end return { description = "Replaces multishell with an advanced version.", dependencies = { "bin/multishell.lua", }, -- When updating the defaults, one should also update bin/shell.lua settings = { { name = "mbs.multishell.enabled", description = "Whether the extended multishell is enabled.", default = true, type = "boolean", }, { name = "mbs.multishell.ctrl", description = "The keycode to use for the default ctrl action", default = keys.leftCtrl, type = "number", }, { name = "mbs.multishell.tab", description = "The keycode to use for the default tab action", default = keys.tab, type = "number", }, { name = "mbs.multishell.shift", description = "The keycode to use for the default shift action", default = keys.leftShift, type = "number", }, { name = "mbs.multishell.restoreTab", description = "Whether the first forward tab action will skip to the last used window", default = true, type = "boolean", } }, enabled = function() return settings.get("mbs.multishell.enabled") end, setup = function(path) if not multishell._mbs then shell.setAlias("multishell", "/" .. fs.combine(path, "bin/multishell.lua")) loadfile(fs.combine(path, "bin/multishell.lua"), _ENV)(shell.getRunningProgram()) end end, }