From: Michał Górny Date: Tue, 17 Sep 2019 07:07:41 +0000 (+0200) Subject: app-text/sgml-common: Restore .cat backup for non-empty too X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=d12ab136a66fcbbd2ae00751f4980dc348d51ed7;p=gentoo.git app-text/sgml-common: Restore .cat backup for non-empty too Signed-off-by: Michał Górny --- diff --git a/app-text/sgml-common/sgml-common-0.6.3-r7.ebuild b/app-text/sgml-common/sgml-common-0.6.3-r7.ebuild index a9d675c8206a..18b9bdd5b860 100644 --- a/app-text/sgml-common/sgml-common-0.6.3-r7.ebuild +++ b/app-text/sgml-common/sgml-common-0.6.3-r7.ebuild @@ -62,7 +62,7 @@ pkg_preinst() { pkg_postinst() { # restore backed up files if necessary for f in sgml-ent.cat sgml-docbook.cat; do - if [[ ! -s ${EROOT}/etc/sgml/${f} ]]; then + if ! cmp -s "${T}/${f}" "${EROOT}/etc/sgml/${f}"; then cp "${T}/${f}" "${EROOT}"/etc/sgml/ || die fi done