Files
Arch-R/packages/tools/autoupdate/install
Stephan Raue 436a24ee09 autoupdate: add repo.conf for releases
Signed-off-by: Stephan Raue <stephan@openelec.tv>
2010-12-23 12:10:00 +01:00

37 lines
1.1 KiB
Bash
Executable File

#!/bin/sh
. config/options $1
mkdir -p $INSTALL/usr/bin
if [ "$OPENELEC_VERSION" = devel ]; then
cp $PKG_DIR/scripts/autoupdate.devel $INSTALL/usr/bin/autoupdate
else
cp $PKG_DIR/scripts/autoupdate.release $INSTALL/usr/bin/autoupdate
fi
mkdir -p $INSTALL/etc
if [ -f $PROJECT_DIR/$PROJECT/autoupdate/repo.conf ]; then
cp $PROJECT_DIR/$PROJECT/autoupdate/repo.conf $INSTALL/etc
else
if [ "$OPENELEC_VERSION" = devel ]; then
cp $PKG_DIR/config/repo.conf.devel $INSTALL/etc/repo.conf
else
cp $PKG_DIR/config/repo.conf.release $INSTALL/etc/repo.conf
fi
fi
if [ -f $PROJECT_DIR/$PROJECT/autoupdate/update.key.db ]; then
cp $PROJECT_DIR/$PROJECT/autoupdate/update.key.db $INSTALL/etc
fi
if [ -f $PROJECT_DIR/$PROJECT/autoupdate/update.conf ]; then
cp $PROJECT_DIR/$PROJECT/autoupdate/update.conf $INSTALL/etc
else
mkdir -p $INSTALL/usr/config
cp $PKG_DIR/config/update.conf $INSTALL/usr/config
fi
mkdir -p $INSTALL/etc/crontabs
echo -e "1 */6 * * *\t/usr/bin/autoupdate" >> $INSTALL/etc/crontabs/root