Move main program files to 'prog', add support for CLI-based interfaces (no boot file).
This commit is contained in:
parent
c0d61d132b
commit
20da3947d9
|
@ -4,7 +4,7 @@ parameter debug is false.
|
|||
|
||||
Bootstrap(
|
||||
"/boot/helicopter",
|
||||
"/init/helicopter",
|
||||
"/prog/helicopter",
|
||||
list("/lib/stabilize_helicopter"),
|
||||
list("/lib/ui"),
|
||||
debug
|
||||
|
|
|
@ -16,7 +16,7 @@ local copied is list(
|
|||
|
||||
Bootstrap(
|
||||
"/boot/rocket",
|
||||
"/init/rocket",
|
||||
"/prog/rocket",
|
||||
compiled,
|
||||
copied,
|
||||
debug
|
||||
|
|
15
lib/boot.ks
15
lib/boot.ks
|
@ -8,11 +8,17 @@ function Bootstrap {
|
|||
if debug {
|
||||
// Open a terminal and run init.
|
||||
CORE:PART:GETMODULE("kOSProcessor"):DOEVENT("Open Terminal").
|
||||
run "/init".
|
||||
if init <> "" {
|
||||
run "/init".
|
||||
}
|
||||
} else {
|
||||
DeletePath("1:" + bootfile).
|
||||
// Set OS to boot and restart.
|
||||
set core:bootfilename to "/init".
|
||||
if init = "" {
|
||||
set CORE:BOOTFILENAME to init.
|
||||
} else {
|
||||
set CORE:BOOTFILENAME to "/init".
|
||||
}
|
||||
reboot.
|
||||
}
|
||||
}
|
||||
|
@ -38,6 +44,11 @@ function copyLibs {
|
|||
|
||||
function compileInit {
|
||||
parameter init, debug is false.
|
||||
|
||||
if init = "" {
|
||||
return.
|
||||
}
|
||||
|
||||
if debug {
|
||||
copypath("0:" + init, "1:/init").
|
||||
return.
|
||||
|
|
Loading…
Reference in New Issue
Block a user