2015-06-26 15:33:14 +00:00
|
|
|
require "language/go"
|
|
|
|
|
|
|
|
class Ipfs < Formula
|
|
|
|
desc "IPFS is The Permanent Web - A new peer-to-peer hypermedia protocol"
|
2015-10-16 14:18:09 +00:00
|
|
|
homepage "https://ipfs.io/"
|
2015-06-26 15:33:14 +00:00
|
|
|
url "https://github.com/ipfs/go-ipfs.git",
|
2015-11-02 12:02:07 +00:00
|
|
|
:tag => "v0.3.9",
|
|
|
|
:revision => "43622bd5eed1f62d53d364dc771bbb500939d9e6"
|
2015-08-05 18:52:39 +00:00
|
|
|
head "https://github.com/ipfs/go-ipfs.git"
|
2015-06-26 15:33:14 +00:00
|
|
|
|
2015-07-01 23:25:38 +00:00
|
|
|
bottle do
|
2015-11-02 20:39:00 +00:00
|
|
|
cellar :any_skip_relocation
|
2015-11-14 11:12:41 +00:00
|
|
|
revision 1
|
|
|
|
sha256 "02ba7f03c7ae2d4540f35ed09f216d3e191595e9fbca8dd8100cf89aac605104" => :el_capitan
|
|
|
|
sha256 "1cc7dd74d1b26a5076e23c40f9cf834ecdc33045fe50846527dfa26f4cfaee9d" => :yosemite
|
|
|
|
sha256 "4294823203d142dd54fe86b2f48f5a7c570ec89dcdc1b8658bdd51967a739664" => :mavericks
|
2015-07-01 23:25:38 +00:00
|
|
|
end
|
|
|
|
|
2015-06-26 15:33:14 +00:00
|
|
|
depends_on "go" => :build
|
2015-11-14 10:30:49 +00:00
|
|
|
depends_on "godep" => :build
|
2015-06-26 15:33:14 +00:00
|
|
|
|
|
|
|
go_resource "github.com/kr/fs" do
|
|
|
|
url "https://github.com/kr/fs.git",
|
|
|
|
:revision => "2788f0dbd16903de03cb8186e5c7d97b69ad387b"
|
|
|
|
end
|
|
|
|
|
|
|
|
go_resource "golang.org/x/tools" do
|
|
|
|
url "https://go.googlesource.com/tools",
|
|
|
|
:using => :git,
|
2015-11-02 12:02:07 +00:00
|
|
|
:revision => "d02228d1857b9f49cd0252788516ff5584266eb6"
|
2015-06-26 15:33:14 +00:00
|
|
|
end
|
|
|
|
|
|
|
|
def install
|
|
|
|
ENV["GOPATH"] = buildpath
|
|
|
|
mkdir_p buildpath/"src/github.com/ipfs/"
|
|
|
|
ln_sf buildpath, buildpath/"src/github.com/ipfs/go-ipfs"
|
|
|
|
Language::Go.stage_deps resources, buildpath/"src"
|
|
|
|
|
|
|
|
cd "cmd/ipfs" do
|
|
|
|
system "make", "build"
|
|
|
|
bin.install "ipfs"
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
test do
|
|
|
|
system "#{bin}/ipfs", "version"
|
|
|
|
end
|
|
|
|
end
|