mirror of https://github.com/Hilbis/Hilbish
fix(cd): make it return 1 exit code on err
parent
630d7dde9c
commit
a140db1610
|
@ -20,8 +20,8 @@ commander.register('cd', function (args)
|
||||||
if err == 1 then
|
if err == 1 then
|
||||||
print('directory does not exist')
|
print('directory does not exist')
|
||||||
end
|
end
|
||||||
bait.throw('command.exit', err)
|
return 1
|
||||||
else bait.throw('command.exit', 0) end
|
end
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
fs.cd(os.getenv 'HOME')
|
fs.cd(os.getenv 'HOME')
|
||||||
|
|
Loading…
Reference in New Issue