summaryrefslogtreecommitdiff
path: root/network/noip/doinst.sh
diff options
context:
space:
mode:
authorDhaby Xiloj <slack.dhabyx@gmail.com>2010-05-11 22:54:59 +0200
committerErik Hanson <erik@slackbuilds.org>2010-05-11 22:54:59 +0200
commit16e7bde2ecb5f2c8b735223402d7b04b9c125b81 (patch)
tree4e7ee1f9cd69241f6a0854c88f93c6709ab4f20d /network/noip/doinst.sh
parented02b9b2702084701a64a2930fd59af568277f6e (diff)
downloadslackbuilds-16e7bde2ecb5f2c8b735223402d7b04b9c125b81.tar.gz
network/noip: Added to 12.1 repository
Diffstat (limited to 'network/noip/doinst.sh')
-rw-r--r--network/noip/doinst.sh15
1 files changed, 15 insertions, 0 deletions
diff --git a/network/noip/doinst.sh b/network/noip/doinst.sh
new file mode 100644
index 0000000000..37f7daeba4
--- /dev/null
+++ b/network/noip/doinst.sh
@@ -0,0 +1,15 @@
+# Handle configuration files
+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...
+}
+# List of configuration files (they should end in .new)
+
+config etc/rc.d/rc.noip.new