Compare commits

..

No commits in common. "144c082d3e065e3ba8094acde677350a58f2154c" and "bc4e0f835ff3cf3dcfcabe27ec6b275e53e57567" have entirely different histories.

4 changed files with 5 additions and 7 deletions

View File

@ -35,11 +35,9 @@ func cd(L *lua.LState) int {
switch e := err.(*os.PathError).Err.Error(); e { switch e := err.(*os.PathError).Err.Error(); e {
case "no such file or directory": case "no such file or directory":
LuaErr(L, 1) LuaErr(L, 1)
case "not a directory":
LuaErr(L, 2)
default: default:
fmt.Printf("Found unhandled error case: %s\n", e) fmt.Printf("Found unhandled error case: %s", e)
fmt.Printf("Report this at https://github.com/Rosettea/Hilbish/issues with the title being: \"fs: unhandled error case %s\", and show what caused it.\n", e) fmt.Printf("Report this at https://github.com/Hilbis/Hilbish/issues with the title being: \"fs: unahndled error case %s\", and show what caused it.\n", e)
LuaErr(L, 213) LuaErr(L, 213)
} }
} }

@ -1 +1 @@
Subproject commit d200fca13df1c47e133b269420223d7e257dbc41 Subproject commit 004bca95d6e848f03e237c46127286f8f064bebc

View File

@ -16,7 +16,7 @@ commander.register('cd', function (args)
path = path .. tostring(args[i]) .. ' ' path = path .. tostring(args[i]) .. ' '
end end
path = path:gsub('$%$','\0'):gsub('${([%w_]+)}', os.getenv) path = path:gsub('$%$','\0'):gsub('${([%w_]+)}', os.getenv)
:gsub('$([%w_]+)', os.getenv):gsub('%z','$') :gsub('$([%w_]+)', os.getenv):gsub('%z','$'):gsub("%s+", "")
if path == '-' then if path == '-' then
path = oldDir path = oldDir

View File

@ -4,7 +4,7 @@ package main
// String vars that are free to be changed at compile time // String vars that are free to be changed at compile time
var ( var (
requirePaths = `';./libs/?/?.lua;./libs/?/init.lua;./?/init.lua;./?/?.lua' requirePaths = `';./libs/?/init.lua;./?/init.lua;./?/?.lua'
.. ';/usr/share/hilbish/libs/?/init.lua;' .. ';/usr/share/hilbish/libs/?/init.lua;'
.. ';/usr/share/hilbish/libs/?/?.lua;' .. ';/usr/share/hilbish/libs/?/?.lua;'
.. hilbish.home .. '/.local/share/hilbish/libs/?/init.lua;' .. hilbish.home .. '/.local/share/hilbish/libs/?/init.lua;'