From d4e5c8e677e3615ad2a5d396422c4bf7eb0ef02c Mon Sep 17 00:00:00 2001 From: "remyabel@65018526f3b5d4c0d36e4b970aacc540e590bf23" Date: Sat, 30 Nov 2019 19:51:42 +0000 Subject: [PATCH] --- ...missions_or_xattr___40__SELinux__41__.mdwn | 21 +++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 doc/todo/Preserve_permissions_or_xattr___40__SELinux__41__.mdwn diff --git a/doc/todo/Preserve_permissions_or_xattr___40__SELinux__41__.mdwn b/doc/todo/Preserve_permissions_or_xattr___40__SELinux__41__.mdwn new file mode 100644 index 0000000000..42318e4479 --- /dev/null +++ b/doc/todo/Preserve_permissions_or_xattr___40__SELinux__41__.mdwn @@ -0,0 +1,21 @@ +Using cp -a, I'm able to preserve the permissions and SELinux context to one repo like so: + + drwx------. 2 user user unconfined_u:object_r:ssh_home_t:s0 4096 Nov 30 14:38 .ssh/ + +But when syncing: + + git annex add --include-dotfiles . || fail + git annex sync --content --message="$(date +%F)" || fail + + for remote in $(git remote) + do + URL=$(git remote get-url "$remote") + cd "$URL" || fail + git annex sync --content --message="$(date +%F)" || fail + done + +Neither the permissions nor the SELinux context are preserved: + + drwxrwxr-x. 2 user user unconfined_u:object_r:user_home_t:s0 4096 Nov 30 14:38 .ssh/ + +Note that I'm unlocking all the files, so I'm not using any symlinks. It would be nice if these could be propagated with sync.