pacdiff: check cmp's exit code rather than output
Signed-off-by: Florian Pritz <bluewind@xinu.at> Signed-off-by: Allan McRae <allan@archlinux.org>
This commit is contained in:
parent
6a804d55dd
commit
495460d717
1 changed files with 2 additions and 2 deletions
|
@ -92,8 +92,8 @@ while IFS= read -u 3 -r -d '' pacfile; do
|
|||
rm -iv "$pacfile"
|
||||
continue
|
||||
fi
|
||||
check="$(cmp "$pacfile" "$file")"
|
||||
if [ -z "${check}" ]; then
|
||||
|
||||
if cmp -s "$pacfile" "$file"; then
|
||||
echo " Files are identical, removing..."
|
||||
rm -v "$pacfile"
|
||||
else
|
||||
|
|
Loading…
Add table
Reference in a new issue