Merge branch 'devel' of dev.sourcefabric.org:airtime into devel
This commit is contained in:
commit
f622aeb025
2 changed files with 20 additions and 3 deletions
|
@ -27,7 +27,15 @@ class Version20110711161043 extends AbstractMigration
|
|||
$cc_files->addColumn('directory', 'integer', array('notnull' => 0, 'default'=> NULL));
|
||||
|
||||
$cc_files->addNamedForeignKeyConstraint('cc_music_dirs_folder_fkey', $cc_music_dirs, array('directory'), array('id'), array('onDelete' => 'CASCADE'));
|
||||
|
||||
|
||||
// before 3) we have to delete all entries in cc_schedule with file_id that are not in cc_file table
|
||||
$this->_addSql("DELETE FROM cc_schedule WHERE cc_schedule.id IN(
|
||||
SELECT cc_schedule.id
|
||||
FROM cc_schedule
|
||||
LEFT JOIN cc_files
|
||||
ON cc_schedule.file_id = cc_files.id
|
||||
WHERE cc_files.id IS NULL)");
|
||||
|
||||
/* 3) create a foreign key relationship from cc_schedule to cc_files */
|
||||
$cc_schedule = $schema->getTable('cc_schedule');
|
||||
$cc_schedule->addNamedForeignKeyConstraint('cc_files_folder_fkey', $cc_files, array('file_id'), array('id'), array('onDelete' => 'CASCADE'));
|
||||
|
|
|
@ -1,5 +1,11 @@
|
|||
#!/bin/bash
|
||||
|
||||
DEB=$(dpkg -s airtime 2> /dev/null | grep Status)
|
||||
if [[ "$DEB" = "Status: install ok installed" ]]; then
|
||||
echo -e "\nDebian package of Airtime detected. Please use the debian package to upgrade.\n"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo -e "\n******************************** Install Begin *********************************"
|
||||
|
||||
# Absolute path to this script
|
||||
|
@ -8,6 +14,7 @@ SCRIPT=`readlink -f $0`
|
|||
SCRIPTPATH=`dirname $SCRIPT`
|
||||
|
||||
VIRTUAL_ENV_DIR="/usr/lib/airtime/airtime_virtualenv"
|
||||
VIRTUAL_ENV_SHARE="/usr/share/python-virtualenv/"
|
||||
if [ ! -d "$VIRTUAL_ENV_DIR" ]; then
|
||||
echo -e "\n*** Creating Virtualenv for Airtime ***"
|
||||
EXTRAOPTION=$(virtualenv --help | grep extra-search-dir)
|
||||
|
@ -15,9 +22,11 @@ if [ ! -d "$VIRTUAL_ENV_DIR" ]; then
|
|||
if [ "$?" -eq "0" ]; then
|
||||
sudo virtualenv --extra-search-dir=${SCRIPTPATH}/3rd_party --no-site-package -p /usr/bin/python2.6 /usr/lib/airtime/airtime_virtualenv
|
||||
else
|
||||
# copy distibute-0.6.10.tar.gz to /usr/share/python-virtualenv/
|
||||
# copy distribute-0.6.10.tar.gz to /usr/share/python-virtualenv/
|
||||
# this is due to the bug in virtualenv 1.4.9
|
||||
cp ${SCRIPTPATH}/3rd_party/distribute-0.6.10.tar.gz /usr/share/python-virtualenv/
|
||||
if [ -d "$VIRTUAL_ENV_SHARE" ]; then
|
||||
cp ${SCRIPTPATH}/3rd_party/distribute-0.6.10.tar.gz /usr/share/python-virtualenv/
|
||||
fi
|
||||
sudo virtualenv --no-site-package -p /usr/bin/python2.6 /usr/lib/airtime/airtime_virtualenv
|
||||
fi
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue