Minor changes to maintainer scripts

This commit is contained in:
Serhii Yeremenko 2023-10-27 15:20:09 +03:00
parent ead8cd6953
commit 087b95d2ed
No known key found for this signature in database
GPG key ID: AB6D54C1C16D2507
3 changed files with 6 additions and 4 deletions

2
debian/postinst vendored
View file

@ -19,7 +19,7 @@ set -e
case "$1" in
configure)
readonly PREV_VERSION="$2"
true
;;
abort-upgrade|abort-remove|abort-deconfigure)
exit 0

4
debian/preinst vendored
View file

@ -15,7 +15,7 @@ set -e
case "$1" in
install|upgrade)
readonly PREV_VERSION="$2"
true
;;
abort-upgrade)
exit 0
@ -45,6 +45,8 @@ rm_symlink() {
rm -f "$1"
}
PREV_VERSION="$2"
# Breaking changes: PapirusDevelopmentTeam/papirus-icon-theme@20bfc4a
# https://github.com/PapirusDevelopmentTeam/papirus-icon-theme/issues/370
if dpkg --compare-versions "$PREV_VERSION" lt "20170304"; then

4
debian/prerm vendored
View file

@ -18,9 +18,9 @@ set -e
case "$1" in
upgrade)
readonly NEW_VERSION="$2"
NEW_VERSION="$2"
# shellcheck disable=SC2016
readonly PREV_VERSION="$(dpkg-query -f='${Version}' --show papirus-icon-theme)"
PREV_VERSION="$(dpkg-query -f='${Version}' --show papirus-icon-theme)"
if dpkg --compare-versions "$PREV_VERSION" gt "$NEW_VERSION"; then
cat >&2 <<- EOF