From 3727709e86ba3243c1de3bf8cabe0c13fa2ea1e7 Mon Sep 17 00:00:00 2001
From: Martin Konecny <martin@martin-ThinkPad-T410.(none)>
Date: Tue, 11 Oct 2011 17:49:35 +0200
Subject: [PATCH 1/7] CC-2870: Create testing infrastructure for testing
 upgrades

-option for downloading devel branch and testing it
---
 dev_tools/fabric/fab_setup.py | 25 +++++++++----------------
 1 file changed, 9 insertions(+), 16 deletions(-)

diff --git a/dev_tools/fabric/fab_setup.py b/dev_tools/fabric/fab_setup.py
index 28dd45b7a..b795756aa 100644
--- a/dev_tools/fabric/fab_setup.py
+++ b/dev_tools/fabric/fab_setup.py
@@ -20,12 +20,9 @@ def test():
     print x.succeeded
     print x.return_code
     
-def download_if_needed(vdi_dir, vdi_snapshot_dir, xml_dir, vm_name, vm_vdi_file, vm_xml_file):
+def download_if_needed(vdi_dir, xml_dir, vm_name, vm_vdi_file, vm_xml_file):
     if not os.path.exists(vdi_dir):
         os.makedirs(vdi_dir)
-        
-    if not os.path.exists(vdi_snapshot_dir):
-        os.makedirs(vdi_snapshot_dir)
     
     if os.path.exists(os.path.join(vdi_dir, vm_vdi_file)):
         print "File %s already exists. No need to re-download" % os.path.join(vdi_dir, vm_vdi_file)
@@ -34,14 +31,7 @@ def download_if_needed(vdi_dir, vdi_snapshot_dir, xml_dir, vm_name, vm_vdi_file,
         print "File %s not found. Downloading" % vm_vdi_file
         local("wget %s/%s/%s -O %s"%(env.vm_download_url, vm_name, vm_vdi_file, os.path.join(vdi_dir, vm_vdi_file)))
         downloaded = True
-       
-    snapshot_file = "{fd4f1d58-2737-49dd-8cd3-aef484d93a9d}.vdi"
-    if os.path.exists(os.path.join(vdi_snapshot_dir, snapshot_file)):
-        print "File %s already exists. No need to re-download" % os.path.join(vdi_snapshot_dir, snapshot_file)
-    else:
-        print "File %s not found. Downloading" % snapshot_file
-        local("wget %s/%s/Snapshots/%s -O %s"%(env.vm_download_url, vm_name, snapshot_file, os.path.join(vdi_snapshot_dir, snapshot_file))) 
-    
+           
     if os.path.exists(os.path.join(xml_dir, vm_xml_file)):
         print "File %s already exists. No need to re-download" % os.path.join(xml_dir, vm_xml_file)
     else:
@@ -59,7 +49,7 @@ def create_fresh_os(os_version, os_arch):
     vdi_snapshot_dir = os.path.expanduser('~/tmp/vms/%s/Snapshots'%vm_name)
     xml_dir = os.path.expanduser('~/.VirtualBox')
     
-    downloaded = download_if_needed(vdi_dir, vdi_snapshot_dir, xml_dir, vm_name, vm_vdi_file, vm_xml_file)
+    downloaded = download_if_needed(vdi_dir, xml_dir, vm_name, vm_vdi_file, vm_xml_file)
 
     if downloaded:
         local("VBoxManage registervm %s"%os.path.join(xml_dir, vm_xml_file), capture=True)
@@ -81,9 +71,6 @@ def create_fresh_os(os_version, os_arch):
     print "Address found %s"%ip_addr
     env.hosts.append(ip_addr)
     env.host_string = ip_addr
-    
-    time.sleep(5)
-    
 
 def ubuntu_lucid_32(fresh_os=True):
     if (fresh_os):
@@ -153,6 +140,12 @@ def airtime_194_tar():
     run('wget http://downloads.sourceforge.net/project/airtime/1.9.4/airtime-1.9.4.tar.gz')
     run('tar xfz airtime-1.9.4.tar.gz')
     sudo('cd ~/airtime-1.9.4/install_full/ubuntu && ./airtime-full-install')
+    
+def airtime_devel():
+    sudo('apt-get update')
+    sudo('apt-get install -y git-core')
+    run('git clone https://github.com/sourcefabric/Airtime.git ~/airtime')
+    sudo('cd ~/airtime && git checkout devel && install_full/ubuntu/airtime-full-install')
 
 
 def airtime_200():

From 701094b74374b0b903a6aafda6bdf1a9301bdbb0 Mon Sep 17 00:00:00 2001
From: James <james@sourcefabric-DX4840.(none)>
Date: Tue, 11 Oct 2011 17:26:56 -0400
Subject: [PATCH 2/7] CC-2946: "Record" should be renamed to "Record from Line
 In"

- fixed
---
 airtime_mvc/application/forms/AddShowRR.php | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/airtime_mvc/application/forms/AddShowRR.php b/airtime_mvc/application/forms/AddShowRR.php
index 84b387b25..7eef2b438 100644
--- a/airtime_mvc/application/forms/AddShowRR.php
+++ b/airtime_mvc/application/forms/AddShowRR.php
@@ -7,7 +7,7 @@ class Application_Form_AddShowRR extends Zend_Form_SubForm
     {
         // Add record element
 		$this->addElement('checkbox', 'add_show_record', array(
-            'label'      => 'Record?',
+            'label'      => 'Record from Line In?',
             'required'   => false,
 		));
 

From e16c8f34113f7bc7f01a2ada4096816cb8fd8e2d Mon Sep 17 00:00:00 2001
From: James <james@sourcefabric-DX4840.(none)>
Date: Tue, 11 Oct 2011 17:29:49 -0400
Subject: [PATCH 3/7] CC-2945: Change "Storage Folder" to "Import Folder"

- fixed
---
 airtime_mvc/application/forms/WatchedDirPreferences.php       | 4 ++--
 .../views/scripts/form/preferences_watched_dirs.phtml         | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/airtime_mvc/application/forms/WatchedDirPreferences.php b/airtime_mvc/application/forms/WatchedDirPreferences.php
index 278a782d7..9e8021839 100644
--- a/airtime_mvc/application/forms/WatchedDirPreferences.php
+++ b/airtime_mvc/application/forms/WatchedDirPreferences.php
@@ -11,7 +11,7 @@ class Application_Form_WatchedDirPreferences extends Zend_Form_SubForm
 
         $this->addElement('text', 'storageFolder', array(
             'class'      => 'input_text',
-            'label'      => 'Airtime\'s Storage Folder:',
+            'label'      => 'Import Folder:',
             'required'   => false,
             'filters'    => array('StringTrim'),
             'value' => '',
@@ -22,7 +22,7 @@ class Application_Form_WatchedDirPreferences extends Zend_Form_SubForm
 
         $this->addElement('text', 'watchedFolder', array(
             'class'      => 'input_text',
-            'label'      => 'Choose a Watched Folder:',
+            'label'      => 'Watched Folders:',
             'required'   => false,
             'filters'    => array('StringTrim'),
             'value' => '',
diff --git a/airtime_mvc/application/views/scripts/form/preferences_watched_dirs.phtml b/airtime_mvc/application/views/scripts/form/preferences_watched_dirs.phtml
index 001112d1a..f384eb752 100644
--- a/airtime_mvc/application/views/scripts/form/preferences_watched_dirs.phtml
+++ b/airtime_mvc/application/views/scripts/form/preferences_watched_dirs.phtml
@@ -16,7 +16,7 @@
                 </ul>
             <?php endif; ?>
         </dd>
-        <dd class="block-display selected-item"><strong>Current Storage Folder:</strong><?php $stor = Application_Model_MusicDir::getStorDir(); echo $stor->getDirectory(); ?></dd>
+        <dd class="block-display selected-item"><strong>Current Import Folder:</strong><?php $stor = Application_Model_MusicDir::getStorDir(); echo $stor->getDirectory(); ?></dd>
 
         <dt id="watchedFolder-label" class="block-display">
             <label class="required" for="watchedFolder"><?php echo $this->element->getElement('watchedFolder')->getLabel() ?></label>

From 55b039c162378d91b1d1fd1fa721d2faba2629c3 Mon Sep 17 00:00:00 2001
From: Martin Konecny <martin@martin-ThinkPad-T410.(none)>
Date: Wed, 12 Oct 2011 14:24:27 +0200
Subject: [PATCH 4/7] CC-2870: Create testing infrastructure for testing
 upgrades

-ignore an error where airtime-full-install would return a non-zero return value.
---
 dev_tools/fabric/fab_setup.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/dev_tools/fabric/fab_setup.py b/dev_tools/fabric/fab_setup.py
index b795756aa..8dbe87bda 100644
--- a/dev_tools/fabric/fab_setup.py
+++ b/dev_tools/fabric/fab_setup.py
@@ -145,7 +145,7 @@ def airtime_devel():
     sudo('apt-get update')
     sudo('apt-get install -y git-core')
     run('git clone https://github.com/sourcefabric/Airtime.git ~/airtime')
-    sudo('cd ~/airtime && git checkout devel && install_full/ubuntu/airtime-full-install')
+    sudo('cd ~/airtime && git checkout devel && install_full/ubuntu/airtime-full-install || true')
 
 
 def airtime_200():

From 24e208d1d6343b692fa3f3a3ef1959540086fc96 Mon Sep 17 00:00:00 2001
From: Martin Konecny <martin@martin-ThinkPad-T410.(none)>
Date: Wed, 12 Oct 2011 14:26:18 +0200
Subject: [PATCH 5/7] CC-2438: Add a button to listen to the stream immediately

-but is now available. Need to ask Vladimir to position it under the "On-Air"
---
 .../application/views/scripts/partialviews/header.phtml        | 3 +++
 airtime_mvc/public/js/airtime/dashboard/playlist.js            | 2 +-
 2 files changed, 4 insertions(+), 1 deletion(-)

diff --git a/airtime_mvc/application/views/scripts/partialviews/header.phtml b/airtime_mvc/application/views/scripts/partialviews/header.phtml
index cfb2906e1..019f1dd4a 100644
--- a/airtime_mvc/application/views/scripts/partialviews/header.phtml
+++ b/airtime_mvc/application/views/scripts/partialviews/header.phtml
@@ -30,6 +30,9 @@
       <li class="time-zone"><span id="time-zone"></span></li>
     </ul>
   </div>
+    <div class="listen-control-block"> 
+        <a class="" href="#"><span>Listen</span></a> 
+    </div> 
   <?php if($this->is_trial){?>
   <div class="trial-info-block">
     <ul>
diff --git a/airtime_mvc/public/js/airtime/dashboard/playlist.js b/airtime_mvc/public/js/airtime/dashboard/playlist.js
index 70203ef81..9310958b3 100644
--- a/airtime_mvc/public/js/airtime/dashboard/playlist.js
+++ b/airtime_mvc/public/js/airtime/dashboard/playlist.js
@@ -260,7 +260,7 @@ function init() {
 
     setupQtip();
     
-    $('#on-air-info').click(function() {
+    $('.listen-control-block').click(function() {
         if (stream_window == null || stream_window.closed)
             stream_window=window.open(baseUrl+"Dashboard/stream-player", 'name', 'width=400,height=216');
         stream_window.focus();

From aa3460963f63b95e8cf567feee57ddb36bd4e7bb Mon Sep 17 00:00:00 2001
From: Martin Konecny <martin@martin-ThinkPad-T410.(none)>
Date: Wed, 12 Oct 2011 14:45:12 +0200
Subject: [PATCH 6/7] CC-2929: More janitorial fixes for Debian/Ubuntu
 compatibility

---
 .../propel/generator/bin/propel-gen.bat       | 32 -------------------
 Changelog => changelog                        |  0
 2 files changed, 32 deletions(-)
 delete mode 100755 airtime_mvc/library/propel/generator/bin/propel-gen.bat
 rename Changelog => changelog (100%)

diff --git a/airtime_mvc/library/propel/generator/bin/propel-gen.bat b/airtime_mvc/library/propel/generator/bin/propel-gen.bat
deleted file mode 100755
index b6607f6b1..000000000
--- a/airtime_mvc/library/propel/generator/bin/propel-gen.bat
+++ /dev/null
@@ -1,32 +0,0 @@
-@echo off
-
-rem *********************************************************************
-rem ** The Propel generator convenience script for Windows based systems
-rem ** $Id$
-rem *********************************************************************
-
-rem This script will do the following:
-rem - check for PHING_COMMAND env, if found, use it.
-rem   - if not found detect php, if found use it, otherwise err and terminate
-rem - check for PROPEL_GEN_HOME env, if found use it
-rem   - if not found error and leave
-
-if "%OS%"=="Windows_NT" @setlocal
-
-rem %~dp0 is expanded pathname of the current script under NT
-set DEFAULT_PROPEL_GEN_HOME=%~dp0..
-
-if "%PROPEL_GEN_HOME%" == "" set PROPEL_GEN_HOME=%DEFAULT_PROPEL_GEN_HOME%
-set DEFAULT_PROPEL_GEN_HOME=
-
-if "%PHING_COMMAND%" == "" set PHING_COMMAND=phing.bat
-
-set nbArgs=0
-for %%x in (%*) do Set /A nbArgs+=1
-if %nbArgs% leq 1 (
-  %PHING_COMMAND% -f "%PROPEL_GEN_HOME%\build.xml" -Dusing.propel-gen=true -Dproject.dir="%CD%" %*
-) else (
-  %PHING_COMMAND% -f "%PROPEL_GEN_HOME%\build.xml" -Dusing.propel-gen=true -Dproject.dir=%*
-)
-
-if "%OS%"=="Windows_NT" @endlocal
diff --git a/Changelog b/changelog
similarity index 100%
rename from Changelog
rename to changelog

From ba6b4ed1f6c92f2bc0cc85c843747064c9b84540 Mon Sep 17 00:00:00 2001
From: Martin Konecny <martin@martin-ThinkPad-T410.(none)>
Date: Wed, 12 Oct 2011 14:52:54 +0200
Subject: [PATCH 7/7] -add missing dependency for liquidsoap

---
 install_full/ubuntu/airtime-full-install | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/install_full/ubuntu/airtime-full-install b/install_full/ubuntu/airtime-full-install
index 2eb1d1222..64beca711 100755
--- a/install_full/ubuntu/airtime-full-install
+++ b/install_full/ubuntu/airtime-full-install
@@ -27,7 +27,8 @@ apt-get -y install tar gzip curl apache2 php5-pgsql libapache2-mod-php5 \
 php-pear php5-gd postgresql odbc-postgresql python2.6 lame libsoundtouch-ocaml \
 libmp3lame-dev libtaglib-ocaml libao-ocaml libmad-ocaml ecasound \
 libesd0 icecast2 libportaudio2 libsamplerate0 rabbitmq-server patch \
-php5-curl mpg123 monit python-virtualenv multitail libcamomile-ocaml-data
+php5-curl mpg123 monit python-virtualenv multitail libcamomile-ocaml-data \
+libvorbis-ocaml
 
 #possibly remove?
 #libvorbis-ocaml-dev