From a9af23fa2eb1830507f1a615a7ee0c42a3ee5c3c Mon Sep 17 00:00:00 2001 From: Ebben Aries Date: Mon, 23 Nov 2015 07:30:50 +0700 Subject: libraries/php-redis: Added (Redis bindings for PHP). Signed-off-by: Willy Sudiarto Raharjo --- libraries/php-redis/doinst.sh | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 libraries/php-redis/doinst.sh (limited to 'libraries/php-redis/doinst.sh') diff --git a/libraries/php-redis/doinst.sh b/libraries/php-redis/doinst.sh new file mode 100644 index 000000000000..3f7d33d7436e --- /dev/null +++ b/libraries/php-redis/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/php.d/redis.ini.new -- cgit v1.2.3