You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
-- On some file systems, we cannot create the directory before renaming. Therefore, remove it and then rename.
97
95
log.trace("Call to uv_fs_rename() while promoting cwd failed.", rename_err)
98
-
fs.async.rmdir(install_path)
99
-
assert(fs.async.dir_exists(cwd), "Current working directory no longer exists after retrying uv_fs_rename().")
100
-
fs.async.rename(cwd, install_path)
96
+
fs.sync.rmdir(install_path)
97
+
assert(fs.sync.dir_exists(cwd), "Current working directory no longer exists after retrying uv_fs_rename().")
98
+
fs.sync.rename(cwd, install_path)
101
99
end
100
+
-- 4. Update cwd
101
+
self.cwd:set(install_path)
102
102
end
103
103
104
104
---@paramrel_pathstring The relative path from the current working directory to change cwd to. Will only restore to the initial cwd after execution of fn (if provided).
0 commit comments