Support proper locating of Nest.toml; Cleanup.

This commit is contained in:
Olivia Brooks
2026-01-26 21:19:51 -05:00
parent ac364caede
commit 56a86b371a
3 changed files with 30 additions and 56 deletions

View File

@@ -35,10 +35,7 @@ pub fn get_javac_ver() -> anyhow::Result<semver::Version> {
}
pub fn set_cwd<P: AsRef<Path>>(path: P) -> io::Result<()> {
let mut cwd = crate::PROJECT_ROOT
.lock()
.expect("Failed to lock Mutex")
.to_owned();
let mut cwd = crate::PROJECT_ROOT.clone();
cwd.push(path.as_ref());
std::env::set_current_dir(cwd)
std::env::set_current_dir(cwd.as_path())
}