Merge branch 'devel' of dev.sourcefabric.org:airtime into devel
This commit is contained in:
commit
45e3fccae2
|
@ -34,13 +34,7 @@ $front->registerPlugin(new RabbitMqPlugin());
|
||||||
|
|
||||||
//localization configuration
|
//localization configuration
|
||||||
$codeset = 'UTF-8';
|
$codeset = 'UTF-8';
|
||||||
$auth = Zend_Auth::getInstance();
|
$lang = Application_Model_Preference::GetLocale().'.'.$codeset;
|
||||||
if ($auth->hasIdentity()) {
|
|
||||||
$id = $auth->getIdentity()->id;
|
|
||||||
$lang = Application_Model_Preference::GetCurrentUserLocale($id).'.'.$codeset;
|
|
||||||
} else {
|
|
||||||
$lang = Application_Model_Preference::GetLocale().'.'.$codeset;
|
|
||||||
}
|
|
||||||
|
|
||||||
putenv("LC_ALL=$lang");
|
putenv("LC_ALL=$lang");
|
||||||
putenv("LANG=$lang");
|
putenv("LANG=$lang");
|
||||||
|
|
|
@ -44,7 +44,7 @@ class PreferenceController extends Zend_Controller_Action
|
||||||
Application_Model_Preference::SetHeadTitle($values["stationName"], $this->view);
|
Application_Model_Preference::SetHeadTitle($values["stationName"], $this->view);
|
||||||
Application_Model_Preference::SetDefaultFade($values["stationDefaultFade"]);
|
Application_Model_Preference::SetDefaultFade($values["stationDefaultFade"]);
|
||||||
Application_Model_Preference::SetAllow3rdPartyApi($values["thirdPartyApi"]);
|
Application_Model_Preference::SetAllow3rdPartyApi($values["thirdPartyApi"]);
|
||||||
Application_Model_Preference::SetLocale($values["locale"]);
|
Application_Model_Preference::SetDefaultLocale($values["locale"]);
|
||||||
Application_Model_Preference::SetTimezone($values["timezone"]);
|
Application_Model_Preference::SetTimezone($values["timezone"]);
|
||||||
Application_Model_Preference::SetWeekStartDay($values["weekStartDay"]);
|
Application_Model_Preference::SetWeekStartDay($values["weekStartDay"]);
|
||||||
|
|
||||||
|
|
|
@ -55,7 +55,7 @@ class Application_Form_GeneralPreferences extends Zend_Form_SubForm
|
||||||
$locale = new Zend_Form_Element_Select("locale");
|
$locale = new Zend_Form_Element_Select("locale");
|
||||||
$locale->setLabel(_("Default Interface Language"));
|
$locale->setLabel(_("Default Interface Language"));
|
||||||
$locale->setMultiOptions(Application_Model_Locale::getLocales());
|
$locale->setMultiOptions(Application_Model_Locale::getLocales());
|
||||||
$locale->setValue(Application_Model_Preference::GetLocale());
|
$locale->setValue(Application_Model_Preference::GetDefaultLocale());
|
||||||
$locale->setDecorators(array('ViewHelper'));
|
$locale->setDecorators(array('ViewHelper'));
|
||||||
$this->addElement($locale);
|
$this->addElement($locale);
|
||||||
|
|
||||||
|
|
|
@ -446,17 +446,17 @@ class Application_Model_Preference
|
||||||
}
|
}
|
||||||
|
|
||||||
// This is the language setting on preferences page
|
// This is the language setting on preferences page
|
||||||
public static function SetLocale($locale)
|
public static function SetDefaultLocale($locale)
|
||||||
{
|
{
|
||||||
self::setValue("locale", $locale);
|
self::setValue("locale", $locale);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static function GetLocale()
|
public static function GetDefaultLocale()
|
||||||
{
|
{
|
||||||
return self::getValue("locale");
|
return self::getValue("locale");
|
||||||
}
|
}
|
||||||
|
|
||||||
public static function GetCurrentUserLocale($id)
|
public static function GetUserLocale($id)
|
||||||
{
|
{
|
||||||
return self::getValue("user_".$id."_locale", true);
|
return self::getValue("user_".$id."_locale", true);
|
||||||
}
|
}
|
||||||
|
@ -466,14 +466,20 @@ class Application_Model_Preference
|
||||||
// When a new user is created they will get the default locale
|
// When a new user is created they will get the default locale
|
||||||
// setting which the admin sets on preferences page
|
// setting which the admin sets on preferences page
|
||||||
if (is_null($locale)) {
|
if (is_null($locale)) {
|
||||||
$locale = self::GetLocale();
|
$locale = self::GetDefaultLocale();
|
||||||
}
|
}
|
||||||
self::setValue("user_".$userId."_locale", $locale, true, $userId);
|
self::setValue("user_".$userId."_locale", $locale, true, $userId);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static function GetUserLocale($userId)
|
public static function GetLocale()
|
||||||
{
|
{
|
||||||
return self::getValue("user_".$userId."_locale");
|
$auth = Zend_Auth::getInstance();
|
||||||
|
if ($auth->hasIdentity()) {
|
||||||
|
$id = $auth->getIdentity()->id;
|
||||||
|
return self::GetUserLocale($id);
|
||||||
|
} else {
|
||||||
|
return self::GetDefaultLocale();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public static function SetStationLogo($imagePath)
|
public static function SetStationLogo($imagePath)
|
||||||
|
|
Binary file not shown.
File diff suppressed because it is too large
Load Diff
|
@ -122,7 +122,7 @@ $(document).ready(function() {
|
||||||
case 'P':
|
case 'P':
|
||||||
$(this).attr('id', 'user-type-P');
|
$(this).attr('id', 'user-type-P');
|
||||||
$(this).attr('user-rights',
|
$(this).attr('user-rights',
|
||||||
$.i18n._('Progam Managers can do the following:')+'<br><br>'+
|
$.i18n._('Program Managers can do the following:')+'<br><br>'+
|
||||||
$.i18n._('View schedule')+'<br>'+
|
$.i18n._('View schedule')+'<br>'+
|
||||||
$.i18n._('View and manage show content')+'<br>'+
|
$.i18n._('View and manage show content')+'<br>'+
|
||||||
$.i18n._('Schedule shows')+'<br>'+
|
$.i18n._('Schedule shows')+'<br>'+
|
||||||
|
|
|
@ -1,2 +1,2 @@
|
||||||
[main]
|
[main]
|
||||||
liquidsoap_tar_url = http://dl.dropbox.com/u/256410/airtime/savonet.tar.gz
|
liquidsoap_tar_url = https://dl.dropbox.com/u/256410/airtime/liquidsoap-jan-02-2013.tar.gz
|
||||||
|
|
|
@ -99,7 +99,7 @@ def create_fresh_os(vm_name, debian=False):
|
||||||
do_local('VBoxManage startvm %s'%vm_name)
|
do_local('VBoxManage startvm %s'%vm_name)
|
||||||
print "Please wait while attempting to acquire IP address"
|
print "Please wait while attempting to acquire IP address"
|
||||||
|
|
||||||
time.sleep(15)
|
time.sleep(30)
|
||||||
|
|
||||||
try_again = True
|
try_again = True
|
||||||
while try_again:
|
while try_again:
|
||||||
|
@ -115,7 +115,7 @@ def create_fresh_os(vm_name, debian=False):
|
||||||
env.host_string = ip_addr
|
env.host_string = ip_addr
|
||||||
|
|
||||||
if debian:
|
if debian:
|
||||||
append('/etc/apt/sources.list', "deb http://www.debian-multimedia.org squeeze main non-free", use_sudo=True)
|
append('/etc/apt/sources.list', "deb http://backports.debian.org/debian-backports squeeze-backports main", use_sudo=True)
|
||||||
|
|
||||||
def ubuntu_lucid_32(fresh_os=True):
|
def ubuntu_lucid_32(fresh_os=True):
|
||||||
if (fresh_os):
|
if (fresh_os):
|
||||||
|
@ -157,6 +157,14 @@ def ubuntu_precise_32(fresh_os=True):
|
||||||
if (fresh_os):
|
if (fresh_os):
|
||||||
create_fresh_os('Ubuntu_12.04_32')
|
create_fresh_os('Ubuntu_12.04_32')
|
||||||
|
|
||||||
|
def ubuntu_quantal_32(fresh_os=True):
|
||||||
|
if (fresh_os):
|
||||||
|
create_fresh_os('Ubuntu_12.10_32')
|
||||||
|
|
||||||
|
def ubuntu_quantal_64(fresh_os=True):
|
||||||
|
if (fresh_os):
|
||||||
|
create_fresh_os('Ubuntu_12.10_64')
|
||||||
|
|
||||||
def debian_squeeze_32(fresh_os=True):
|
def debian_squeeze_32(fresh_os=True):
|
||||||
if (fresh_os):
|
if (fresh_os):
|
||||||
create_fresh_os('Debian_Squeeze_32', debian=True)
|
create_fresh_os('Debian_Squeeze_32', debian=True)
|
||||||
|
@ -165,6 +173,14 @@ def debian_squeeze_64(fresh_os=True):
|
||||||
if (fresh_os):
|
if (fresh_os):
|
||||||
create_fresh_os('Debian_Squeeze_64', debian=True)
|
create_fresh_os('Debian_Squeeze_64', debian=True)
|
||||||
|
|
||||||
|
def debian_wheezy_32(fresh_os=True):
|
||||||
|
if (fresh_os):
|
||||||
|
create_fresh_os('Debian_Wheezy_32')
|
||||||
|
|
||||||
|
def debian_wheezy_64(fresh_os=True):
|
||||||
|
if (fresh_os):
|
||||||
|
create_fresh_os('Debian_Wheezy_64')
|
||||||
|
|
||||||
|
|
||||||
def compile_liquidsoap(filename="liquidsoap"):
|
def compile_liquidsoap(filename="liquidsoap"):
|
||||||
|
|
||||||
|
@ -179,11 +195,11 @@ def compile_liquidsoap(filename="liquidsoap"):
|
||||||
do_sudo('''apt-get install -y --force-yes ocaml-findlib libao-ocaml-dev libportaudio-ocaml-dev \
|
do_sudo('''apt-get install -y --force-yes ocaml-findlib libao-ocaml-dev libportaudio-ocaml-dev \
|
||||||
libmad-ocaml-dev libtaglib-ocaml-dev libalsa-ocaml-dev libtaglib-ocaml-dev libvorbis-ocaml-dev \
|
libmad-ocaml-dev libtaglib-ocaml-dev libalsa-ocaml-dev libtaglib-ocaml-dev libvorbis-ocaml-dev \
|
||||||
libspeex-dev libspeexdsp-dev speex libladspa-ocaml-dev festival festival-dev \
|
libspeex-dev libspeexdsp-dev speex libladspa-ocaml-dev festival festival-dev \
|
||||||
libsamplerate-dev libxmlplaylist-ocaml-dev libxmlrpc-light-ocaml-dev libflac-dev \
|
libsamplerate-dev libxmlplaylist-ocaml-dev libflac-dev \
|
||||||
libxml-dom-perl libxml-dom-xpath-perl patch autoconf libmp3lame-dev \
|
libxml-dom-perl libxml-dom-xpath-perl patch autoconf libmp3lame-dev \
|
||||||
libcamomile-ocaml-dev libcamlimages-ocaml-dev libtool libpulse-dev libjack-dev
|
libcamomile-ocaml-dev libcamlimages-ocaml-dev libtool libpulse-dev libjack-dev \
|
||||||
camlidl libfaad-dev libpcre-ocaml-dev''')
|
camlidl libfaad-dev libpcre-ocaml-dev''')
|
||||||
|
#libxmlrpc-light-ocaml-dev
|
||||||
root = '/home/martin/src'
|
root = '/home/martin/src'
|
||||||
do_run('mkdir -p %s' % root)
|
do_run('mkdir -p %s' % root)
|
||||||
|
|
||||||
|
@ -202,13 +218,14 @@ camlidl libfaad-dev libpcre-ocaml-dev''')
|
||||||
#do_run('cd %s/liquidsoap-1.0.1-full && make' % root)
|
#do_run('cd %s/liquidsoap-1.0.1-full && make' % root)
|
||||||
#get('%s/liquidsoap-1.0.1-full/liquidsoap-1.0.1/src/liquidsoap' % root, filename)
|
#get('%s/liquidsoap-1.0.1-full/liquidsoap-1.0.1/src/liquidsoap' % root, filename)
|
||||||
|
|
||||||
do_run('cd %s/savonet && cp PACKAGES.minimal PACKAGES' % root)
|
do_run('cd %s/liquidsoap && cp PACKAGES.minimal PACKAGES' % root)
|
||||||
sed('%s/savonet/PACKAGES' % root, '#ocaml-portaudio', 'ocaml-portaudio')
|
sed('%s/liquidsoap/PACKAGES' % root, '#ocaml-portaudio', 'ocaml-portaudio')
|
||||||
sed('%s/savonet/PACKAGES' % root, '#ocaml-alsa', 'ocaml-alsa')
|
sed('%s/liquidsoap/PACKAGES' % root, '#ocaml-alsa', 'ocaml-alsa')
|
||||||
sed('%s/savonet/PACKAGES' % root, '#ocaml-pulseaudio', 'ocaml-pulseaudio')
|
sed('%s/liquidsoap/PACKAGES' % root, '#ocaml-pulseaudio', 'ocaml-pulseaudio')
|
||||||
sed('%s/savonet/PACKAGES' % root, '#ocaml-faad', 'ocaml-faad')
|
sed('%s/liquidsoap/PACKAGES' % root, '#ocaml-faad', 'ocaml-faad')
|
||||||
do_run('cd %s/savonet && make clean' % root)
|
do_run('cd %s/liquidsoap && ./bootstrap' % root)
|
||||||
do_run('cd %s/savonet && ./bootstrap' % root)
|
do_run('cd %s/liquidsoap && ./configure' % root)
|
||||||
do_run('cd %s/savonet && ./configure' % root)
|
do_run('cd %s/liquidsoap && make clean' % root)
|
||||||
do_run('cd %s/savonet && make' % root)
|
do_run('cd %s/liquidsoap && make' % root)
|
||||||
get('%s/savonet/liquidsoap/src/liquidsoap' % root, filename)
|
do_sudo('chmod 755 %s/liquidsoap/liquidsoap/src/liquidsoap' % root)
|
||||||
|
get('%s/liquidsoap/liquidsoap/src/liquidsoap' % root, filename)
|
||||||
|
|
|
@ -2,8 +2,9 @@
|
||||||
|
|
||||||
exec 2>&1
|
exec 2>&1
|
||||||
|
|
||||||
ubuntu_versions=("ubuntu_lucid_32" "ubuntu_lucid_64" "ubuntu_maverick_32" "ubuntu_maverick_64" "ubuntu_natty_32" "ubuntu_natty_64" "ubuntu_oneiric_32" "ubuntu_oneiric_64" "debian_squeeze_32" "debian_squeeze_64" "ubuntu_precise_32" "ubuntu_precise_64")
|
ubuntu_versions=("ubuntu_lucid_32" "ubuntu_lucid_64" "ubuntu_natty_32" "ubuntu_natty_64" "ubuntu_oneiric_32" "ubuntu_oneiric_64" "debian_squeeze_32" "debian_squeeze_64" "ubuntu_precise_32" "ubuntu_precise_64" "ubuntu_quantal_32" "ubuntu_quantal_64" "debian_wheezy_32" "debian_wheezy_64")
|
||||||
|
|
||||||
|
#ubuntu_versions=("ubuntu_quantal_64")
|
||||||
num1=${#ubuntu_versions[@]}
|
num1=${#ubuntu_versions[@]}
|
||||||
|
|
||||||
mkdir -p ./upgrade_logs2
|
mkdir -p ./upgrade_logs2
|
||||||
|
|
Loading…
Reference in New Issue