make diff not exit 1 when comparing password files

ubuntu/yakkety
Oliver Grawert 10 years ago
parent 4578b6a4d0
commit 5dc7bbd2ab

6
debian/changelog vendored

@ -1,3 +1,9 @@
livecd-rootfs (2.261) UNRELEASED; urgency=medium
* make diff not exit 1 if we show the diff for passwd, shadow, group etc
-- Oliver Grawert <ogra@ubuntu.com> Wed, 29 Oct 2014 16:44:25 +0100
livecd-rootfs (2.260) vivid; urgency=medium livecd-rootfs (2.260) vivid; urgency=medium
* properly redirect error output in 99zz-check-uid-gid.chroot so it ends up * properly redirect error output in 99zz-check-uid-gid.chroot so it ends up

@ -15,26 +15,26 @@ gshadow_orig_length=$(cat /etc/gshadow.orig | wc -l)
if [ "$passwd_hash" != "$passwd_orig_hash" ]; then if [ "$passwd_hash" != "$passwd_orig_hash" ]; then
echo "/etc/passwd has changed during setup." >&2 echo "/etc/passwd has changed during setup." >&2
echo "The new /etc/passwd md5sum is: $passwd_hash" >&2 echo "The new /etc/passwd md5sum is: $passwd_hash" >&2
diff -Nrup /etc/passwd.orig /etc/passwd >&2 diff -Nrup /etc/passwd.orig /etc/passwd >&2 || true
ERRCNT=1 ERRCNT=1
fi fi
if [ "$shadow_hash" != "$shadow_orig_hash" ]; then if [ "$shadow_hash" != "$shadow_orig_hash" ]; then
echo "/etc/shadow has changed during setup." >&2 echo "/etc/shadow has changed during setup." >&2
echo "The new /etc/shadow md5sum is: $shadow_hash" >&2 echo "The new /etc/shadow md5sum is: $shadow_hash" >&2
diff -Nrup /etc/shadow.orig /etc/shadow >&2 diff -Nrup /etc/shadow.orig /etc/shadow >&2 || true
ERRCNT=1 ERRCNT=1
fi fi
if [ "$group_length" != "$group_orig_length" ]; then if [ "$group_length" != "$group_orig_length" ]; then
echo "/etc/group has changed during setup." >&2 echo "/etc/group has changed during setup." >&2
diff -Nrup /etc/group.orig /etc/group >&2 diff -Nrup /etc/group.orig /etc/group >&2 || true
ERRCNT=1 ERRCNT=1
fi fi
if [ "$gshadow_length" != "$gshadow_orig_length" ]; then if [ "$gshadow_length" != "$gshadow_orig_length" ]; then
echo "/etc/gshadow has changed during setup." >&2 echo "/etc/gshadow has changed during setup." >&2
diff -Nrup /etc/gshadow.orig /etc/gshadow >&2 diff -Nrup /etc/gshadow.orig /etc/gshadow >&2 || true
ERRCNT=1 ERRCNT=1
fi fi

Loading…
Cancel
Save