feat: handle links as well
This commit is contained in:
parent
e3503e5e9f
commit
82c765a562
1 changed files with 1 additions and 0 deletions
|
@ -37,6 +37,7 @@ run_latehook() {
|
|||
rm -rf /new_root/.new_etc/pacman.d
|
||||
cp -a /new_root/.update_rootfs/etc/pacman.d /new_root/.new_etc/pacman.d
|
||||
(cd /new_root/.update_rootfs/etc && find . -type f | grep -Fxv -f <(cd "/new_root/.new_etc" && find . -type f) | xargs -n 1 sh -c 'mkdir -p "/new_root/.new_etc/$(dirname "$1")"; cp -a "$1" /new_root/.new_etc/$(dirname "$1")' sh)
|
||||
(cd /new_root/.update_rootfs/etc && find . -type l | grep -Fxv -f <(cd "/new_root/.new_etc" && find . -type l) | xargs -n 1 sh -c 'mkdir -p "/new_root/.new_etc/$(dirname "$1")"; cp -a "$1" /new_root/.new_etc/$(dirname "$1")' sh)
|
||||
mv /new_root/etc /new_root/.old.etc || :
|
||||
mv /new_root/.new_etc /new_root/etc
|
||||
|
||||
|
|
Loading…
Reference in a new issue