From 723d110c30606be3a10ab1f863c8f0dab7791b4e Mon Sep 17 00:00:00 2001 From: Steven Pledger Date: Wed, 12 May 2010 23:33:47 +0200 Subject: system/rar: Added to 12.2 repository --- system/rar/doinst.sh | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 system/rar/doinst.sh (limited to 'system/rar/doinst.sh') diff --git a/system/rar/doinst.sh b/system/rar/doinst.sh new file mode 100644 index 0000000000..9c74f0a6d2 --- /dev/null +++ b/system/rar/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/rarfiles.lst.new + -- cgit v1.2.3