feat: throw hilbish.exit hook (closes #99)

windows-fixes
TorchedSammy 2022-03-06 10:23:32 -04:00
parent 0b1b5bff2d
commit 3805f13369
Signed by: sammyette
GPG Key ID: 904FC49417B44DCD
2 changed files with 2 additions and 0 deletions

View File

@ -172,6 +172,7 @@ input:
if err == io.EOF {
// Exit if user presses ^D (ctrl + d)
hooks.Em.Emit("hilbish.exit")
break
}
if err != nil {

View File

@ -45,6 +45,7 @@ commander.register('cd', function (args)
end)
commander.register('exit', function()
bait.throw('hilbish.exit')
os.exit(0)
end)