slackbuilds_ponce/desktop/lxlauncher/doinst.sh
Matteo Bernardini fe3c3f50da desktop/lxlauncher: Updated for version 0.2.3.
Signed-off-by: Matteo Bernardini <ponce@slackbuilds.org>
2014-09-05 23:21:10 +07:00

16 lines
483 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/xdg/lxlauncher/gtkrc.new
config etc/xdg/lxlauncher/settings.conf.new
config etc/xdg/menus/lxlauncher-applications.menu.new