Skip to content

Instantly share code, notes, and snippets.

@fabiomcosta
Created March 28, 2012 03:15
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save fabiomcosta/2223256 to your computer and use it in GitHub Desktop.
Save fabiomcosta/2223256 to your computer and use it in GitHub Desktop.
proposed phantomjs formula
require 'formula'
class NeedsSnowLeopardOrNewer < Requirement
def satisfied?
MacOS.snow_leopard?
end
def message
"phantomjs requires Mac OS X 10.6 (Snow Leopard) or newer."
end
end
class Phantomjs < Formula
url "http://phantomjs.googlecode.com/files/phantomjs-1.5.0-macosx-static.zip"
homepage 'http://www.phantomjs.org/'
sha1 'b87152ce691e7ed1937d30f86bc706a408d47f64'
depends_on NeedsSnowLeopardOrNewer.new
def install
libexec.install "bin/phantomjs"
libexec.install "bin/Info.plist"
bin.install_symlink "#{libexec}/phantomjs" => "phantomjs"
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment