Fix: renaming of /var/lib/mympd/smartpls/*.dist files

This commit is contained in:
jcorporation
2018-10-01 23:11:14 +02:00
parent 044eaa2ad4
commit 2eeddc9786
3 changed files with 25 additions and 15 deletions
+8 -5
View File
@@ -52,12 +52,15 @@ post_upgrade() {
# move smartpls into place unless already existing
for PLDIST in /var/lib/mympd/smartpls/*.dist
do
PLS=$(basename $PLDIST .dist)
if [ -f /var/lib/mympd/smartpls/$PLS ]
if [ -f "$PLDIST" ]
then
rm $PLDIST
else
mv $PLDIST /var/lib/mympd/smartpls/$PLS
PLS=$(basename $PLDIST .dist)
if [ -f /var/lib/mympd/smartpls/$PLS ]
then
rm $PLDIST
else
mv -v $PLDIST /var/lib/mympd/smartpls/$PLS
fi
fi
done
+8 -5
View File
@@ -66,12 +66,15 @@ fi
# move smartpls into place unless already existing
for PLDIST in /var/lib/mympd/smartpls/*.dist
do
PLS=$(basename $PLDIST .dist)
if [ -f /var/lib/mympd/smartpls/$PLS ]
if [ -f "$PLDIST" ]
then
rm $PLDIST
else
mv $PLDIST /var/lib/mympd/smartpls/$PLS
PLS=$(basename $PLDIST .dist)
if [ -f /var/lib/mympd/smartpls/$PLS ]
then
rm $PLDIST
else
mv -v $PLDIST /var/lib/mympd/smartpls/$PLS
fi
fi
done
+9 -5
View File
@@ -36,15 +36,19 @@ fi
# move smartpls into place unless already existing
for PLDIST in /var/lib/mympd/smartpls/*.dist
do
PLS=$(basename $PLDIST .dist)
if [ -f /var/lib/mympd/smartpls/$PLS ]
if [ -f "$PLDIST" ]
then
rm $PLDIST
else
mv $PLDIST /var/lib/mympd/smartpls/$PLS
PLS=$(basename $PLDIST .dist)
if [ -f /var/lib/mympd/smartpls/$PLS ]
then
rm $PLDIST
else
mv -v $PLDIST /var/lib/mympd/smartpls/$PLS
fi
fi
done
# move config into place unless already existing
if [ ! -f /etc/mympd/mympd.conf ]
then