diff --git a/nature/commands/cd.lua b/nature/commands/cd.lua index 284d420..9f532ca 100644 --- a/nature/commands/cd.lua +++ b/nature/commands/cd.lua @@ -17,11 +17,13 @@ commander.register('cd', function (args, sinks) sinks.out:writeln(path) end + local absPath = fs.abs(path) local ok, err = pcall(function() fs.cd(path) end) if not ok then sinks.out:writeln(err) return 1 end + bait.throw('cd', path, oldPath) - bait.throw('hilbish.cd', fs.abs(path), oldPath) + bait.throw('hilbish.cd', absPath, oldPath) end)