2010-02-09, 04:46
I made some changes, but it's mostly intact. You should grab the SVN and test it out to verify. The smart installer will be comming soon.
Code:
SYMLINKDisabled () {
#Grab command line arguments
VIDEODIR=$1
FILENAME=$2
#Make sure we got command line arguments
if [ -z "${VIDEODIR}" -o -z "${FILENAME}" ] && [ ! -h "${VIDEODIR}/${FILENAME}" ]; then
echo "ATTEMPTED DATABASE DELETE:FILE DOES NOT EXIST OR IS NOT A SYMBOLIC LINK.">>"$mythicalLibrarian"/output.log
else
#Remove recording entry from 'mythconverg' mysql database
echo "REMOVING - ${FILENAME} - THUMBNAILS - DATABASE ENTRIES">>"$mythicalLibrarian"/output.log
echo "REMOVING - ${FILENAME} - THUMBNAILS - DATABASE ENTRIES"
mysql -u$MySQLuser -p$MySQLpass -e "use '$MySQLMythDb' ; delete from recorded where basename like '${FILENAME}'; "
#Remove symbolink file and thumbnails
rm -f ${VIDEODIR}/${FILENAME}
rm -f ${VIDEODIR}/${FILENAME}.*
fi
}