File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
packaging/common/cfengine-hub Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -397,13 +397,13 @@ if [ -d $PREFIX/httpd/htdocs ]; then
397397 # Purge all files in httpd/htdocs with exceptions listed in preserve_during_upgrade.txt
398398 cf_console echo " Keeping only what's listed in preserve_during_upgrade.txt file"
399399 PRESERVE_FILTER=" ` generate_preserve_filter` "
400- find " $PREFIX /httpd/htdocs" $PRESERVE_FILTER -type f -print0 | xargs -0 rm
400+ find " $PREFIX /httpd/htdocs" $PRESERVE_FILTER -type f -print0 | xargs --no-run-if-empty - 0 rm
401401 elif [ -d $PREFIX /share/GUI ]; then
402402 # Remove only files copied from share/GUI to httpd/htdocs
403403 cf_console echo " Using share/GUI as template"
404404 ( cd $PREFIX /share/GUI
405405 # Make list of files in share/GUI and remove "them" from httpd/htdocs
406- find -type f -print0 | ( cd ../../httpd/htdocs/ && xargs -0 rm -f )
406+ find -type f -print0 | ( cd ../../httpd/htdocs/ && xargs --no-run-if-empty - 0 rm -f )
407407 )
408408 else
409409 # Purge all files in httpd/htdocs with hardcoded exceptions:
@@ -413,7 +413,7 @@ if [ -d $PREFIX/httpd/htdocs ]; then
413413 find " $PREFIX /httpd/htdocs" -not \( -path " $PREFIX /httpd/htdocs/public/tmp" -prune \) \
414414 -not \( -name " cf_robot.php" \) \
415415 -not \( -name " settings.ldap.php" \) \
416- -type f -print0 | xargs -0 -r rm
416+ -type f -print0 | xargs --no-run-if-empty -0 rm
417417 fi
418418 if [ -d $PREFIX /share/GUI -a " x${PKG_TYPE} " = " xrpm" ]; then
419419 # Make sure old files are not copied over together with new files later
You can’t perform that action at this time.
0 commit comments