v2 #2
1 changed files with 7 additions and 0 deletions
commit
bd2ba0b2e7
|
|
@ -42,6 +42,13 @@ fn main() -> Result<()> {
|
||||||
archive.mode(HeaderMode::Complete);
|
archive.mode(HeaderMode::Complete);
|
||||||
archive.follow_symlinks(false);
|
archive.follow_symlinks(false);
|
||||||
for path in path {
|
for path in path {
|
||||||
|
if !path.exists() {
|
||||||
|
println!(
|
||||||
|
"warn: path {} does not exist, and will not be cached",
|
||||||
|
path.display()
|
||||||
|
);
|
||||||
|
continue;
|
||||||
|
}
|
||||||
if path.is_dir() {
|
if path.is_dir() {
|
||||||
// we actually want to write out all the directory contents
|
// we actually want to write out all the directory contents
|
||||||
archive.append_dir_all("", path).unwrap();
|
archive.append_dir_all("", path).unwrap();
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue