diff options
author | Niels Horn <niels.horn@gmail.com> | 2011-10-09 11:54:03 -0500 |
---|---|---|
committer | Robby Workman <rworkman@slackbuilds.org> | 2011-10-11 21:20:30 -0500 |
commit | b3de66000fd0804c344047cd1a97bec87a647cb2 (patch) | |
tree | e2f360bfc8b9bb064d00f3e4273722c03b89a996 /multimedia/minidlna/doinst.sh | |
parent | 414c1df02f42ae6faf281f62cc7982427f8d14d7 (diff) | |
download | slackbuilds-b3de66000fd0804c344047cd1a97bec87a647cb2.tar.gz |
multimedia/minidlna: Added (mini DLNA server)
Signed-off-by: Erik Hanson <erik@slackbuilds.org>
Diffstat (limited to 'multimedia/minidlna/doinst.sh')
-rw-r--r-- | multimedia/minidlna/doinst.sh | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/multimedia/minidlna/doinst.sh b/multimedia/minidlna/doinst.sh new file mode 100644 index 0000000000..7626d3a507 --- /dev/null +++ b/multimedia/minidlna/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/minidlna.conf.new |