diff --git a/Formula/xulrunner.rb b/Formula/xulrunner.rb index 09c303283e..bd3e313e88 100644 --- a/Formula/xulrunner.rb +++ b/Formula/xulrunner.rb @@ -2,23 +2,12 @@ require "formula" # speed up head clone, see: https://developer.mozilla.org/en-US/docs/Developer_Guide/Source_Code/Mercurial/Bundles class HgBundleDownloadStrategy < CurlDownloadStrategy - def hgpath - MercurialDownloadStrategy.new(@name, @resource).hgpath - end - - def fetch - @repo = @url.split("|").last - @url = @url.split("|").first - super() - end - def stage - safe_system "mkdir mozilla-central" - safe_system hgpath, "init", "mozilla-central" + mkdir "mozilla-central" + quiet_safe_system hgpath, "init", "mozilla-central" chdir - safe_system hgpath, "unbundle", @tarball_path - safe_system hgpath, "pull", @repo - safe_system hgpath, "update" + quiet_safe_system hgpath, "unbundle", cached_location + quiet_safe_system hgpath, "pull", "--update", meta.fetch(:repo) end end @@ -50,8 +39,8 @@ class Xulrunner < Formula end head do - url "https://ftp.mozilla.org/pub/mozilla.org/firefox/bundles/mozilla-central.hg|https://hg.mozilla.org/mozilla-central/", - :using => HgBundleDownloadStrategy + url "https://ftp.mozilla.org/pub/mozilla.org/firefox/bundles/mozilla-central.hg", + :using => HgBundleDownloadStrategy, :repo => "https://hg.mozilla.org/mozilla-central" depends_on :hg => :build depends_on "gettext" => :build end