changeset 199:38fc07fb6aad

extract file on linux
author Jeff Hammel <jhammel@mozilla.com>
date Wed, 02 Feb 2011 15:15:38 -0800
parents 1a50b63c73a3
children c1c804aae348
files autobot/process/factory.py
diffstat 1 files changed, 8 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/autobot/process/factory.py	Wed Feb 02 15:08:54 2011 -0800
+++ b/autobot/process/factory.py	Wed Feb 02 15:15:38 2011 -0800
@@ -57,13 +57,20 @@
                                        WithProperties('%(firefox_url)s'),
                                        '-O',
                                        WithProperties('%(firefox_bundle)s')],
+                              description='download Firefox',
                               haltOnFailure=True))
 
     # three cases:
     # - linux has firefox in a .tar.bz2 file
     # - mac has firefox in a .dmg file [TODO]
     # - windows has firefox in a .zip file
-    
+    if platform['os'] == 'linux':
+      self.addStep(ShellCommand(command=['tar', 'xjvf',
+                                         WithProperties('%(firefox_bundle)s')],
+                                haltOnFailure=True
+                                ))
+    else:
+      raise NotImplementedError("FirefoxDownloader doesn't know how to work with your os: %s" % platform['os'])
 
 
 class SourceFactory(BuildFactory):