SlackBuildsOrg/audio/xmp/doinst.sh
Erik Hanson 00fe1301c6 audio/xmp: Added (Extended Module Player)
Signed-off-by: dsomero <xgizzmo@slackbuilds.org>
2012-04-08 10:54:24 -04:00

15 lines
408 B
Bash

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/xmp/xmp.conf.new
config etc/xmp/modules.conf.new