an echo program

This commit is contained in:
overflowerror 2014-08-08 14:23:51 +02:00
parent dca3a9fd8c
commit c628da5309

View file

@ -0,0 +1,13 @@
var Echo = function() {
}
Echo.prototype = new Program();
Echo.prototype.main = function(args) {
args.splice(0, 1);
this.output(args.join(" ") + "\n");
this.exit(0);
}
ProgramManager.programs.push({
command: "echo",
code: Echo
})