Write to the proper data/input/shared directory for elevation. #82

It was always using the current directory, which breaks when running the
UI map importer from game/. [rebuild] [release]
This commit is contained in:
Dustin Carlino 2021-04-04 09:58:40 -07:00
parent 437d3eb064
commit b8318917a8

View File

@ -17,7 +17,7 @@ pub fn add_data(map: &mut RawMap, timer: &mut Timer) -> Result<()> {
timer.start("run elevation_lookups");
std::fs::create_dir_all("elevation_output")?;
std::fs::create_dir_all("data/input/shared/elevation")?;
std::fs::create_dir_all(abstio::path_shared_input("elevation"))?;
let pwd = std::env::current_dir()?.display().to_string();
// Because elevation_lookups has so many dependencies, just depend on Docker.
let status = Command::new("docker")
@ -32,8 +32,8 @@ pub fn add_data(map: &mut RawMap, timer: &mut Timer) -> Result<()> {
// our data/input/shared directory.
.arg("--mount")
.arg(format!(
"type=bind,source={}/data/input/shared/elevation,target=/elevation/data",
pwd
"type=bind,source={},target=/elevation/data",
abstio::path_shared_input("elevation")
))
.arg("--mount")
.arg(format!(