strip: Dereference path if it is a symlink

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
This commit is contained in:
Michael Tremer
2022-02-04 16:47:46 +00:00
committed by Peter Müller
parent bbedf54c52
commit f84c2cda03

View File

@@ -61,7 +61,7 @@ function _strip() {
}
for path in ${paths[@]}; do
for file in $(find "${path}" -xdev "${excludes[@]}" -type f \( -perm -0100 -or -perm -0010 -or -perm -0001 \) 2>/dev/null); do
for file in $(find -H "${path}" -xdev "${excludes[@]}" -type f \( -perm -0100 -or -perm -0010 -or -perm -0001 \) 2>/dev/null); do
_strip "${file}" || exit $?
done
done