mirror of
https://github.com/curioustorvald/tsvm.git
synced 2026-03-11 13:41:50 +09:00
a way to run program with arguments
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
const PROMPT_TEXT = ">";
|
||||
let PROMPT_TEXT = ">";
|
||||
let CURRENT_DRIVE = "A";
|
||||
|
||||
let shell_pwd = [""];
|
||||
@@ -15,6 +15,11 @@ function greet() {
|
||||
}
|
||||
|
||||
|
||||
let shell = {};
|
||||
shell.test = "command.js test string";
|
||||
if (exec_args !== undefined) return shell;
|
||||
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
println("Starting TVDOS...");
|
||||
@@ -47,9 +52,10 @@ while (true) {
|
||||
println();
|
||||
try {
|
||||
println("You entered: " + cmdbuf);
|
||||
|
||||
}
|
||||
catch (e) {
|
||||
println(e);
|
||||
printerrln(e);
|
||||
}
|
||||
finally {
|
||||
if (cmdbuf.trim().length > 0)
|
||||
@@ -91,4 +97,6 @@ while (true) {
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return 0;
|
||||
Reference in New Issue
Block a user