aboutsummaryrefslogtreecommitdiffstats
path: root/boot.lua
blob: 4226cba6f6aeed96fe3db7d4a59096cc444a7369 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
require 'moonscript'

MODS = MODS or {}
-- table.insert(MODS, 'base')
-- table.insert(MODS, 'debug')
-- table.insert(MODS, 'math')
-- table.insert(MODS, 'time')

for _,mod in ipairs(MODS) do
 package.loaded[mod] = nil
end
for _,mod in ipairs(MODS) do
  require(mod)
end
for k,v in pairs(require 'base') do
  _G[k] = v
end

function reload()
 package.loaded.boot = nil
 require 'boot'
end