fix: -a instead of -r

This commit is contained in:
Rudra B.S. 2023-11-22 17:02:19 +05:30
parent bd688e01b9
commit 4f7426ace8

View file

@ -27,7 +27,7 @@ run_latehook() {
# Detect if /etc stage is active. # Detect if /etc stage is active.
if [[ -f /new_root/.etc-stage ]]; then if [[ -f /new_root/.etc-stage ]]; then
# Create new /etc. # Create new /etc.
rm -rf /new_root/.new_etc; cp -r /new_root/etc /new_root/.new_etc rm -rf /new_root/.new_etc; cp -a /new_root/etc /new_root/.new_etc
(cd /new_root/.new_etc && find . -type f -print0 | grep -Fxvz -f <(cd "/new_root/.update_rootfs/etc" && find . -type f) | xargs -0 rm -f) (cd /new_root/.new_etc && find . -type f -print0 | grep -Fxvz -f <(cd "/new_root/.update_rootfs/etc" && find . -type f) | xargs -0 rm -f)
(cd /new_root/.new_etc && find . -type l -print0 | grep -Fxvz -f <(cd "/new_root/.update_rootfs/etc" && find . -type l) | xargs -0 rm -f) (cd /new_root/.new_etc && find . -type l -print0 | grep -Fxvz -f <(cd "/new_root/.update_rootfs/etc" && find . -type l) | xargs -0 rm -f)
mkdir -p /.old.varlib mkdir -p /.old.varlib