| 209 | } |
| 210 | |
| 211 | int cliLuaAbsolute(lua_State* L) { |
| 212 | auto path = fs::path(cliGetString(L, 1)); |
| 213 | auto base = lua_gettop(L) >= 2 && !lua_isnil(L, 2) ? fs::path(cliGetString(L, 2)) : fs::current_path(); |
| 214 | auto result = cliAbsolutePath(path, base).string(); |
| 215 | lua_pushlstring(L, result.c_str(), result.size()); |
| 216 | return 1; |
| 217 | } |
| 218 | |
| 219 | int cliLuaExists(lua_State* L) { |
| 220 | std::error_code err; |
nothing calls this directly
no test coverage detected