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
let path_that_must_be_ignored = source_dir.path().join(".movement/celestia/c1860ae680eb2d91927b/.celestia-app/keyring-test");
520
525
521
526
fs::create_dir_all(path_that_must_be_ignored.parent().context("failed to get parent directory for path that must be ignored")?).context("failed to create directory")?;
522
-
fs::write(path_that_must_be_ignored,"test").context("failed to write file that must not be ignored")?;
527
+
// write a file that must not be ignored
528
+
fs::write(path_that_must_be_ignored.clone(),"test").context("failed to write file that must not be ignored")?;
529
+
// set permissions to 000 on the file and then on the parent directory
530
+
fs::set_permissions(path_that_must_be_ignored.clone(),Permissions::from_mode(0o000)).context("failed to set permissions on file that must not be ignored")?;
531
+
fs::set_permissions(path_that_must_be_ignored.parent().context("failed to get parent directory for path that must be ignored")?,Permissions::from_mode(0o000)).context("failed to set permissions on parent directory that must not be ignored")?;
523
532
524
533
copy_dir_recursive_with_ignore(source_dir.path(),["celestia"], target_dir.path()).context("failed to copy directory")?;
0 commit comments