homebrew-core/Formula/tutum.rb

88 lines
2.8 KiB
Ruby
Raw Normal View History

2014-10-20 11:34:14 +00:00
require "formula"
class Tutum < Formula
homepage "https://www.tutum.co/"
url "https://github.com/tutumcloud/tutum-cli/archive/v0.11.0.1.tar.gz"
sha1 "501b0ec1582b741b2eca81bb5a27b11499b42f0c"
bottle do
cellar :any
2015-01-11 20:01:46 +00:00
revision 1
sha1 "9ed06a00ba4580e9e322a3ff97df7fa6ecb33047" => :yosemite
sha1 "2c1be29999b79f4438c1f81aca8f98c0c2cd93cc" => :mavericks
sha1 "b19df240260d468f20b6b8c8acaab6a277b9c9aa" => :mountain_lion
end
2014-10-20 11:34:14 +00:00
depends_on :python if MacOS.version <= :snow_leopard
depends_on "libyaml"
resource "ago" do
url "https://pypi.python.org/packages/source/a/ago/ago-0.0.6.tar.gz"
sha1 "b48b99151370de0c1642748a3f3b206649645d8d"
end
resource "docker-py" do
url "https://pypi.python.org/packages/source/d/docker-py/docker-py-0.5.3.tar.gz"
sha1 "11708a7021e3d0d522e145c057256d7d2acaec07"
2014-10-20 11:34:14 +00:00
end
resource "pyyaml" do
url "https://pypi.python.org/packages/source/P/PyYAML/PyYAML-3.10.tar.gz"
sha1 "476dcfbcc6f4ebf3c06186229e8e2bd7d7b20e73"
2014-10-20 11:34:14 +00:00
end
resource "python-tutum" do
url "https://pypi.python.org/packages/source/p/python-tutum/python-tutum-0.11.0.tar.gz"
sha1 "a8b011697fe015c468eeeed33ce242631e11d39a"
2014-10-20 11:34:14 +00:00
end
resource "backports.ssl-match-hostname" do
url "https://pypi.python.org/packages/source/b/backports.ssl_match_hostname/backports.ssl_match_hostname-3.4.0.2.tar.gz"
sha1 "da4e41f3b110279d2382df47ac1e4f10c63cf954"
end
2014-10-20 11:34:14 +00:00
resource "six" do
url "https://pypi.python.org/packages/source/s/six/six-1.9.0.tar.gz"
sha1 "d168e6d01f0900875c6ecebc97da72d0fda31129"
end
resource "python-dateutil" do
url "https://pypi.python.org/packages/source/p/python-dateutil/python-dateutil-2.2.tar.gz"
sha1 "fbafcd19ea0082b3ecb17695b4cb46070181699f"
end
resource "requests" do
url "https://pypi.python.org/packages/source/r/requests/requests-2.5.1.tar.gz"
sha1 "f906c441be2f0e7a834cbf701a72788d3ac3d144"
2014-10-20 11:34:14 +00:00
end
resource "tabulate" do
url "https://pypi.python.org/packages/source/t/tabulate/tabulate-0.7.2.tar.gz"
sha1 "da057c6d4faab9847436c3221c98f34911e623df"
end
resource "websocket-client" do
url "https://pypi.python.org/packages/source/w/websocket-client/websocket-client-0.23.0.tar.gz"
sha1 "3348c226eb44324417db777e962fec6bda8134b9"
end
2014-10-20 11:34:14 +00:00
def install
ENV.prepend_create_path "PYTHONPATH", libexec/"vendor/lib/python2.7/site-packages"
2014-10-20 11:34:14 +00:00
resources.each do |r|
r.stage do
system "python", *Language::Python.setup_install_args(libexec/"vendor")
end
2014-10-20 11:34:14 +00:00
end
ENV.prepend_create_path "PYTHONPATH", libexec/"lib/python2.7/site-packages"
system "python", *Language::Python.setup_install_args(libexec)
2014-10-20 11:34:14 +00:00
bin.install Dir[libexec/"bin/*"]
bin.env_script_all_files(libexec/"bin", :PYTHONPATH => ENV["PYTHONPATH"])
2014-10-20 11:34:14 +00:00
end
test do
system "#{bin}/tutum", "container"
end
end