changeset 217:5148132de9b6

stub out first part of getting firefox downloader to work on mac....i love you, mr jobs
author Jeff Hammel <jhammel@mozilla.com>
date Tue, 15 Feb 2011 16:44:19 -0800
parents 85052c5ab8f1
children c82a46673ce9
files autobot/process/factory.py
diffstat 1 files changed, 11 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/autobot/process/factory.py	Wed Feb 09 14:52:17 2011 -0800
+++ b/autobot/process/factory.py	Tue Feb 15 16:44:19 2011 -0800
@@ -76,8 +76,18 @@
                                 haltOnFailure=True))
       self.addStep(SetProperty(property='firefox',
                                command=self.abspath('firefox/firefox.exe')))
+    elif platform['os'] == 'mac':
+      # See:
+      # http://mxr.mozilla.org/mozilla-central/source/build/package/mac_osx/unpack-diskimage
+      # http://hg.mozilla.org/qa/mozmill-automation/file/default/libs/install.py
+      self.addStep(ShellCommand(command=['rm', '-rf', 'firefox-tmp']))
+      self.addStep(ShellCommand(command=['mkdir', 'firefox-tmp'],
+                                haltOnFailure=True))
+      self.addStep(ShellCommand(command=['hdiutil', 'attach',
+                                         WithProperties('%(firefox_bundle)s'),
+                                         '-mountpoint', 'firefox-tmp'],
+                                haltOnFailure=True))
     else:
-      # TODO: mac
       raise NotImplementedError("FirefoxDownloader doesn't know how to work with your os: %s" % platform['os'])
 
   def abspath(self, path):