From 1d2836e8045c1931be467f74575a46559867ff44 Mon Sep 17 00:00:00 2001 From: fosslinux Date: Mon, 27 Jan 2025 13:15:51 +1100 Subject: [PATCH] Don't checksum symlinks when uninstalling symlinks are removed separately later. It doesn't really make sense to checksum them - the file they are pointing to could have been deleted. --- steps/helpers.sh | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/steps/helpers.sh b/steps/helpers.sh index 86544286..d5393526 100755 --- a/steps/helpers.sh +++ b/steps/helpers.sh @@ -141,6 +141,8 @@ uninstall() { if [ -z "$(ls -A "/${file}")" ]; then rmdir "/${file}" fi + elif [ -h "${file}" ]; then + symlinks="${symlinks} ${file}" else # in some cases we might be uninstalling a file that has already been overwritten # in this case we don't want to remove it @@ -149,9 +151,6 @@ uninstall() { if [ "${in_fs}" = "${in_pkg}" ]; then rm -f "/${file}" fi - if [ -h "${file}" ]; then - symlinks="${symlinks} ${file}" - fi fi done < ../filelist rm -f ../filelist