diff options
author | Alan Hicks <alan@lizella.net> | 2010-05-11 15:01:27 +0200 |
---|---|---|
committer | Robby Workman <rworkman@slackbuilds.org> | 2010-05-11 15:01:27 +0200 |
commit | 744f4f4f4e2c0d8f297f8913f2966ddbf031e7a6 (patch) | |
tree | d35b3fd62742ef820a97beb706d877032ae0de5f /network/dovecot/doinst.sh | |
parent | f64750f981a5800dc6347c6c68d28004ce949dfc (diff) | |
download | slackbuilds-744f4f4f4e2c0d8f297f8913f2966ddbf031e7a6.tar.gz |
network/dovecot: Initial import
Diffstat (limited to 'network/dovecot/doinst.sh')
-rw-r--r-- | network/dovecot/doinst.sh | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/network/dovecot/doinst.sh b/network/dovecot/doinst.sh new file mode 100644 index 0000000000..1142a48442 --- /dev/null +++ b/network/dovecot/doinst.sh @@ -0,0 +1,15 @@ +#!/bin/sh + +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/dovecot-example.conf.new |