From 8ca96fb6039c261bb4fddfadc6a1fea9e003191e Mon Sep 17 00:00:00 2001 From: James Meyer Date: Sun, 21 Mar 2010 12:30:37 -0500 Subject: mediasrv: changed install file to not create symlinks if the dest is already present modifed run file so that it's not as chatty about "which" ref 590 --- abs/extra-testing/mediaserv/mediaserv.install | 18 +++++++++++++++--- abs/extra-testing/mediaserv/run | 2 +- 2 files changed, 16 insertions(+), 4 deletions(-) diff --git a/abs/extra-testing/mediaserv/mediaserv.install b/abs/extra-testing/mediaserv/mediaserv.install index 7a26077..4a9de8e 100644 --- a/abs/extra-testing/mediaserv/mediaserv.install +++ b/abs/extra-testing/mediaserv/mediaserv.install @@ -1,8 +1,20 @@ # arg 1: the new package version + + post_install() { - ln -s /myth/mediaserv /home/mythtv/.mediaserv - ln -s /myth/pretty /myth/mediaserv/media/tv - ln -s /myth/video /myth/mediaserv/media/video + if [ ! -e /home/mythtv/.mediaserv ] + then + ln -s /myth/mediaserv /home/mythtv/.mediaserv + fi + + if [ ! -e /myth/mediaserv/media/tv ] + then + ln -s /myth/pretty /myth/mediaserv/media/tv + fi + if [ ! -e /myth/mediaserv/media/video ] + then + ln -s /myth/video /myth/mediaserv/media/video + fi chown -R mythtv.mythtv /myth/mediaserv add_service.sh mediaserv sv start mediaserv diff --git a/abs/extra-testing/mediaserv/run b/abs/extra-testing/mediaserv/run index 82a1705..fbd1c97 100644 --- a/abs/extra-testing/mediaserv/run +++ b/abs/extra-testing/mediaserv/run @@ -4,5 +4,5 @@ export TERM=linux . /etc/rc.conf . /etc/rc.d/functions stat_runit "Starting mediaserv" -exec su mythtv -c "/usr/bin/mediaserv" +exec su mythtv -c "/usr/bin/mediaserv" 2>/dev/null wait -- cgit v0.12