summaryrefslogtreecommitdiffstats
path: root/desktop/slim/doinst.sh
diff options
context:
space:
mode:
author Martin Lefebvre <dadexter@gmail.com>2010-05-11 19:44:04 +0200
committer Robby Workman <rworkman@slackbuilds.org>2010-05-11 19:44:04 +0200
commitbb084a69e3bcf9256c96aff1599424e436b83622 (patch)
tree3d39de010fa08d229dcb543860a080c7528f56d7 /desktop/slim/doinst.sh
parent022be4b55de0d6dc9b5d6397775a87a29a172bc1 (diff)
downloadslackbuilds-bb084a69e3bcf9256c96aff1599424e436b83622.tar.gz
slackbuilds-bb084a69e3bcf9256c96aff1599424e436b83622.tar.xz
desktop/slim: Updated for version 1.3.0
Diffstat (limited to '')
-rw-r--r--desktop/slim/doinst.sh16
1 files changed, 12 insertions, 4 deletions
diff --git a/desktop/slim/doinst.sh b/desktop/slim/doinst.sh
index de76815af0..49a1fd7229 100644
--- a/desktop/slim/doinst.sh
+++ b/desktop/slim/doinst.sh
@@ -2,16 +2,24 @@
config() {
NEW="$1"
- OLD="`dirname $NEW`/`basename $NEW .new`"
+ 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
+ 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/slim.conf.new
-config /etc/rc.d/rc.slim.new
+# Keep same perms on rc.slim.new:
+if [ -e etc/rc.d/rc.slim ]; then
+ cp -a etc/rc.d/rc.slim etc/rc.d/rc.slim.new.incoming
+ cat etc/rc.d/rc.slim.new > etc/rc.d/rc.slim.new.incoming
+ mv etc/rc.d/rc.slim.new.incoming etc/rc.d/rc.slim.new
+fi
+
+config etc/rc.d/rc.slim.new
+config etc/slim.conf.new
+