summaryrefslogtreecommitdiff
path: root/network/bmon/doinst.sh
diff options
context:
space:
mode:
authorB. Watson <yalhcru@gmail.com>2014-08-26 23:57:14 +0200
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2014-08-30 14:22:22 +0700
commit45424c4039fdf760b200e9b7fc1ec305bf6c6c0e (patch)
tree6622695d40a22f762eaf0bcebd5fc1de3fd9e093 /network/bmon/doinst.sh
parent0afef319ef8aff875b0cce76041f5e50bff59f7a (diff)
downloadslackbuilds-45424c4039fdf760b200e9b7fc1ec305bf6c6c0e.tar.gz
network/bmon: Updated for version 3.4.
Signed-off-by: Matteo Bernardini <ponce@slackbuilds.org>
Diffstat (limited to 'network/bmon/doinst.sh')
-rw-r--r--network/bmon/doinst.sh14
1 files changed, 14 insertions, 0 deletions
diff --git a/network/bmon/doinst.sh b/network/bmon/doinst.sh
new file mode 100644
index 0000000000..f40d18e245
--- /dev/null
+++ b/network/bmon/doinst.sh
@@ -0,0 +1,14 @@
+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/bmon.conf.new