fix root; fix directory creation
This commit is contained in:
@@ -162,7 +162,10 @@ pub(crate) fn sync(
|
||||
|
||||
if !target.exists() {
|
||||
println!("[info] copying from {:?} to {:?}.", source, target);
|
||||
fs::create_dir_all(target.parent().unwrap())?;
|
||||
let parent = target.parent().unwrap();
|
||||
if !parent.exists() {
|
||||
fs::create_dir_all(parent)?;
|
||||
}
|
||||
fs::copy(source, target)?;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user