summaryrefslogtreecommitdiff
path: root/ham/twhamqth/doinst.sh
diff options
context:
space:
mode:
authorJK Wood <joshuakwood@gmail.com>2019-12-29 14:34:13 -0600
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2019-12-31 18:06:22 +0700
commit9269961568317e76114be9fd4234d19b59f45fd4 (patch)
tree8055580b59e6f324a60afd8f06f06b7cf2c32b30 /ham/twhamqth/doinst.sh
parente515a72b0cf2448c50e062e6afae2e8e18df512a (diff)
downloadslackbuilds-9269961568317e76114be9fd4234d19b59f45fd4.tar.gz
ham/twhamqth: Updated for version 2.0.
Signed-off-by: Robby Workman <rworkman@slackbuilds.org>
Diffstat (limited to 'ham/twhamqth/doinst.sh')
-rw-r--r--ham/twhamqth/doinst.sh16
1 files changed, 16 insertions, 0 deletions
diff --git a/ham/twhamqth/doinst.sh b/ham/twhamqth/doinst.sh
index 5fb28930db..a648bc1b7f 100644
--- a/ham/twhamqth/doinst.sh
+++ b/ham/twhamqth/doinst.sh
@@ -1,3 +1,19 @@
+config() {
+ NEW="$1"
+ OLD="$(dirname $NEW)/$(basename $NEW .new)"
+ # If there's no config file by that name, mv it over:
+ if [ ! -r $OLD ]; then
+ mv $NEW $OLD
+ elif [ "$(cat $OLD | md5sum)" = "$(cat $NEW | md5sum)" ]; then
+ # toss the redundant copy
+ rm $NEW
+ fi
+ # Otherwise, we leave the .new copy for the admin to consider...
+}
+
+config etc/X11/app-defaults/TwHamQTH.new
+
if [ -x /usr/bin/update-desktop-database ]; then
/usr/bin/update-desktop-database -q usr/share/applications >/dev/null 2>&1
fi
+