From b5b96ee9026e8b7efa04363dde5d63decfce707c Mon Sep 17 00:00:00 2001 From: Yalla-One Date: Tue, 11 May 2010 20:01:28 +0200 Subject: network/GeoIP: Added to 12.0 repository --- network/GeoIP/doinst.sh | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 network/GeoIP/doinst.sh (limited to 'network/GeoIP/doinst.sh') diff --git a/network/GeoIP/doinst.sh b/network/GeoIP/doinst.sh new file mode 100644 index 0000000000..abb22def77 --- /dev/null +++ b/network/GeoIP/doinst.sh @@ -0,0 +1,16 @@ +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/GeoIP.conf.default.new +config etc/GeoIP.conf.new + -- cgit v1.2.3