summaryrefslogtreecommitdiff
path: root/development/tig/doinst.sh
diff options
context:
space:
mode:
authorGrigorios Bouzakis <grbzks@gmail.com>2010-05-11 22:53:41 +0200
committerMichiel van Wessem <michiel@slackbuilds.org>2010-05-11 22:53:41 +0200
commit560ce2e72566f3677b85a18a7c8b34ef99b5e664 (patch)
treed004e737c5e4d083c5da451792f80f5af7f8cfc4 /development/tig/doinst.sh
parentc9bbf5d47fecf839a39a26f2dfc10c362a3f3c7c (diff)
downloadslackbuilds-560ce2e72566f3677b85a18a7c8b34ef99b5e664.tar.gz
development/tig: Added to 12.1 repository
Diffstat (limited to 'development/tig/doinst.sh')
-rw-r--r--development/tig/doinst.sh17
1 files changed, 17 insertions, 0 deletions
diff --git a/development/tig/doinst.sh b/development/tig/doinst.sh
new file mode 100644
index 0000000000..a39b214088
--- /dev/null
+++ b/development/tig/doinst.sh
@@ -0,0 +1,17 @@
+#!/bin/sh
+
+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/tigrc.new
+