diff --git a/exec/default.js b/exec/default.js index f8e3c401726b76448c53511429d8cfecf2f77a72..32c7239c7ea11cfb8bbcd033e8cdd5ba08e5c7a9 100644 --- a/exec/default.js +++ b/exec/default.js @@ -203,10 +203,7 @@ while(bbs.online && !js.terminated) { cmd = console.getstr(); if(cmd == '!') cmd = last_str_cmd; - var script = system.mods_dir + "str_cmds.js"; - if(!file_exists(script)) - script = system.exec_dir + "str_cmds.js"; - js.exec(script, {}, cmd); + load({}, "str_cmds.js", cmd); last_str_cmd = cmd; continue; } diff --git a/exec/str_cmds.js b/exec/str_cmds.js index 47ecd91eeb4d5019e74e867fa7eee1e1d72e5225..100257f92d0657a28c90f10e43950694b052e4b1 100644 --- a/exec/str_cmds.js +++ b/exec/str_cmds.js @@ -351,6 +351,11 @@ function str_cmds(str) return; } + if(str=="HELP") + writeln("RELOAD\tReload the current shell (if JavaScript)."); + if(str=="RELOAD") + exit(0); + if(str=="HELP") writeln("SLOG\tExecutes the slog utility to display system statistics."); if(str=="SLOG") {