support MOTDs (#19)

This commit is contained in:
Kan18 2019-08-13 13:14:11 -04:00 committed by kepler155c
parent 6e6d4b81cd
commit 2f597d0dc4
1 changed files with 5 additions and 0 deletions

View File

@ -3,6 +3,7 @@ local parentShell = _ENV.shell
_ENV.shell = { }
local fs = _G.fs
local settings = _G.settings
local shell = _ENV.shell
local sandboxEnv = setmetatable({ }, { __index = _G })
@ -673,6 +674,10 @@ local history = History.load('usr/.shell_history', 25)
term.setBackgroundColor(_colors.backgroundColor)
term.clear()
if settings.get("motd.enabled") then
shell.run("motd")
end
while not bExit do
if config.displayDirectory then
term.setTextColour(_colors.directoryTextColor)