@@ -15,14 +15,20 @@ class Devd < Formula
1515 sha256 cellar : :any_skip_relocation , x86_64_linux : "9718a2a8ec148738db0127f1dc4a0e7a1ca6c4e69d2505f02a9580230ea30b91"
1616 end
1717
18+ depends_on "dep" => :build
1819 depends_on "go" => :build
1920
21+ # Support go 1.17, remove when upstream patch is merged/released
22+ # Patch is the `dep` equivalent of https://github.com/cortesi/devd/pull/117
23+ patch :DATA
24+
2025 def install
2126 ENV [ "GOPATH" ] = buildpath
2227 ENV [ "GO111MODULE" ] = "auto"
2328 ( buildpath /"src/github.com/cortesi/devd" ) . install buildpath . children
2429 cd "src/github.com/cortesi/devd" do
25- system "go" , "build" , *std_go_args , "./cmd/devd"
30+ system "dep" , "ensure" , "-vendor-only"
31+ system "go" , "build" , *std_go_args ( ldflags : "-s -w" ) , "./cmd/devd"
2632 end
2733 end
2834
@@ -39,3 +45,27 @@ def install
3945 assert_equal "Hello World!\n " , output
4046 end
4147end
48+
49+ __END__
50+ diff --git a/Gopkg.lock b/Gopkg.lock
51+ index 437a8b5..257a307 100644
52+ --- a/Gopkg.lock
53+ +++ b/Gopkg.lock
54+ @@ -172,14 +172,15 @@
55+
56+ [[projects]]
57+ branch = "master"
58+ - digest = "1:e6d1805ead5b8f2439808f76187f54042ed35ee26eb9ca63127259a0e612b119"
59+ + digest = "1:d5b479606f9456b8e3200dbe988b32e211f824d6a612c4cfac46c1a31458d568"
60+ name = "golang.org/x/sys"
61+ packages = [
62+ + "internal/unsafeheader",
63+ "unix",
64+ "windows",
65+ ]
66+ pruneopts = ""
67+ - revision = "b4a75ba826a64a70990f11a225237acd6ef35c9f"
68+ + revision = "63515b42dcdf9544f4e6a02fd7632793fde2f72d"
69+
70+ [[projects]]
71+ digest = "1:15d017551627c8bb091bde628215b2861bed128855343fdd570c62d08871f6e1"
0 commit comments