kOS/compileall.ks

30 lines
585 B
Plaintext
Raw Normal View History

2021-07-23 21:50:11 +00:00
// Intended to be run from volume 0 for checking compiled sizes.
2021-08-01 05:23:39 +00:00
switch to 0.
compileHere().
function compileDir {
parameter dir.
cd("dir").
compileHere().
cd("..").
}
function compileHere {
local fileList is list().
list files in fileList.
for f in fileList {
if f:ISFILE {
compile f.
} else {
compileDir(f).
}
2021-07-23 21:50:11 +00:00
}
2021-08-01 05:23:39 +00:00
}
2021-07-23 21:50:11 +00:00
// TODO: might be neat to actually do a filesize comparison and print a report or something,
// specifically iterating files NOT to compile.
// TODO: We could hypothetically even integrate this with the bootstrapper.