diff options
author | Niels Horn <niels.horn@gmail.com> | 2010-05-13 00:59:55 +0200 |
---|---|---|
committer | David Somero <xgizzmo@slackbuilds.org> | 2010-05-13 00:59:55 +0200 |
commit | 9a981fcfe5780b39a066d4aad73fdb7bc38d3a5a (patch) | |
tree | 0a8623e06e9f418468354bb1282bf1446e611b59 /network/cacti/doinst.sh | |
parent | c1c07adda66f6ee1324bb5bb80fa17744071df05 (diff) | |
download | slackbuilds-9a981fcfe5780b39a066d4aad73fdb7bc38d3a5a.tar.gz |
network/cacti: Added to 13.0 repository
Diffstat (limited to 'network/cacti/doinst.sh')
-rw-r--r-- | network/cacti/doinst.sh | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/network/cacti/doinst.sh b/network/cacti/doinst.sh new file mode 100644 index 0000000000..adb1b10ae8 --- /dev/null +++ b/network/cacti/doinst.sh @@ -0,0 +1,15 @@ +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/cacti/config.php.new + |