3 filelist="mediaprovider.h media.h media.cc mediaplayer.h mediaplayer.cc mediafile.h mediafile.cc serialize.h serialize.cc vdrcommand.h mediaproviderids.h"
5 echo "usage: $0 [-f] [clientdir]"
6 echo " if clientdir is not given VOMPCLIENT has to be set"
16 echo $1 | sed 's/\.cc$/.c/'
19 if [ "$1" = "-h" ] ; then
24 if [ "$1" = "-f" ] ; then
30 if [ "$clientdir" = "" ] ; then
33 if [ "$clientdir" = "" ] ; then
34 echo neither clientdir provided nor VOMPCLIENT set
38 backupdir=../vompserver-backup
39 if [ "$VOMPSERVERBACKUP" != "" ] ; then
40 backupdir=$VOMPSERVERBACKUP
43 be=`date +%Y%m%d%H%M%S`
45 backupdir=$backupdir/$be
46 echo "backing up to $backupdir"
47 mkdir -p $backupdir || error "unable to create backup directorry $backupdir"
51 [ ! -f $clientdir/$file ] && error "$clientdir/$file not found"
56 ofile=`translateName $file`
57 if [ -f $ofile -a ! -L $ofile ] ; then
58 echo backing up $ofile to $backupdir/$ofile
59 cp $ofile $backupdir/$ofile || error "failed to backup $ofile"
62 if [ "$force" = 1 ] ; then
65 if [ ! -L $ofile ] ; then
66 echo linking $clientdir/$file $ofile
67 ln -s $clientdir/$file $ofile || error "unable to link $clientdir/$file to $ofile"
69 echo $ofile already exists as link, skip