summaryrefslogtreecommitdiff
path: root/network/rejik/doinst.sh
diff options
context:
space:
mode:
authorOleg A. Deordiev <admin@ifconfig.com.ua>2014-04-18 09:29:18 +0700
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2014-04-23 07:51:42 +0700
commitc26b971d080371f47752bd706c9cfc317b34affd (patch)
treec0ce708a86ecaae867435fe99857ade505a830b3 /network/rejik/doinst.sh
parent6234dabd2741a19fb07e72f04c32e4c9e884e1a8 (diff)
downloadslackbuilds-c26b971d080371f47752bd706c9cfc317b34affd.tar.gz
network/rejik: Added (squid redirector).
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'network/rejik/doinst.sh')
-rw-r--r--network/rejik/doinst.sh14
1 files changed, 14 insertions, 0 deletions
diff --git a/network/rejik/doinst.sh b/network/rejik/doinst.sh
new file mode 100644
index 0000000000..d14634e173
--- /dev/null
+++ b/network/rejik/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/squid/redirector.conf.dist.new