Skip to content

Commit bf1406a

Browse files
committed
Brew formula update for vproxy version v0.14
1 parent 5fd06a1 commit bf1406a

File tree

1 file changed

+35
-31
lines changed

1 file changed

+35
-31
lines changed

Formula/vproxy-head.rb

Lines changed: 35 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -5,16 +5,16 @@
55
class VproxyHead < Formula
66
desc "Zero-config virtual proxies with tls"
77
homepage "https://github.com/jittering/vproxy"
8-
version "0.13"
8+
version "0.14"
99

1010
depends_on "go"
1111
depends_on "mkcert"
1212
depends_on "nss"
1313

1414
on_macos do
15-
if Hardware::CPU.arm?
16-
url "https://github.com/jittering/vproxy/releases/download/v0.13/vproxy_darwin_arm64.tar.gz"
17-
sha256 "47200b524e03254fe985be48d1ae0cf618f5ee64dabe4079edc33305f6e9941d"
15+
if Hardware::CPU.intel?
16+
url "https://github.com/jittering/vproxy/releases/download/v0.14/vproxy_darwin_amd64.tar.gz"
17+
sha256 "4eccce4d3918c278c4b314db0c774308f7cfe953107c464ab5f75a45aae4310f"
1818

1919
def install
2020
if build.head?
@@ -28,9 +28,9 @@ def install
2828
(bash_completion/"vproxy").write bash_output
2929
end
3030
end
31-
if Hardware::CPU.intel?
32-
url "https://github.com/jittering/vproxy/releases/download/v0.13/vproxy_darwin_amd64.tar.gz"
33-
sha256 "caf506dfc81a603f74cb26c1442d241e57857b959957b848b0b34f7ae1709a24"
31+
if Hardware::CPU.arm?
32+
url "https://github.com/jittering/vproxy/releases/download/v0.14/vproxy_darwin_arm64.tar.gz"
33+
sha256 "68fab1adbd87ed6868e3180f94d2ec56e89ace73e9af2a5d8f507b46f426b688"
3434

3535
def install
3636
if build.head?
@@ -47,36 +47,40 @@ def install
4747
end
4848

4949
on_linux do
50-
if Hardware::CPU.arm? && Hardware::CPU.is_64_bit?
51-
url "https://github.com/jittering/vproxy/releases/download/v0.13/vproxy_linux_arm64.tar.gz"
52-
sha256 "37370e1e055907ce4d76ccaa371088ec6bb9c3610a12729dbbcca1733f379b93"
50+
if Hardware::CPU.intel?
51+
if Hardware::CPU.is_64_bit?
52+
url "https://github.com/jittering/vproxy/releases/download/v0.14/vproxy_linux_amd64.tar.gz"
53+
sha256 "315b9199be6a1885dec97995cc2957cff726dd6e5049d4fc618eeb104ad168da"
54+
55+
def install
56+
if build.head?
57+
system "go", "build", *std_go_args(output: "build/vproxy"), "./bin/vproxy"
58+
bin.install "build/vproxy"
59+
else
60+
bin.install "vproxy"
61+
end
5362

54-
def install
55-
if build.head?
56-
system "go", "build", *std_go_args(output: "build/vproxy"), "./bin/vproxy"
57-
bin.install "build/vproxy"
58-
else
59-
bin.install "vproxy"
63+
bash_output = Utils.safe_popen_read("#{bin}/vproxy", "bash_completion")
64+
(bash_completion/"vproxy").write bash_output
6065
end
61-
62-
bash_output = Utils.safe_popen_read("#{bin}/vproxy", "bash_completion")
63-
(bash_completion/"vproxy").write bash_output
6466
end
6567
end
66-
if Hardware::CPU.intel?
67-
url "https://github.com/jittering/vproxy/releases/download/v0.13/vproxy_linux_amd64.tar.gz"
68-
sha256 "ace40aa6642a717e4def1a3cc5ef71ce4951e23e00ebb986f97eb0eef0361a9d"
68+
if Hardware::CPU.arm?
69+
if Hardware::CPU.is_64_bit?
70+
url "https://github.com/jittering/vproxy/releases/download/v0.14/vproxy_linux_arm64.tar.gz"
71+
sha256 "8da11976f617ae989f83e67c549199d5e306753488aea11afe2a7424e358c1c7"
72+
73+
def install
74+
if build.head?
75+
system "go", "build", *std_go_args(output: "build/vproxy"), "./bin/vproxy"
76+
bin.install "build/vproxy"
77+
else
78+
bin.install "vproxy"
79+
end
6980

70-
def install
71-
if build.head?
72-
system "go", "build", *std_go_args(output: "build/vproxy"), "./bin/vproxy"
73-
bin.install "build/vproxy"
74-
else
75-
bin.install "vproxy"
81+
bash_output = Utils.safe_popen_read("#{bin}/vproxy", "bash_completion")
82+
(bash_completion/"vproxy").write bash_output
7683
end
77-
78-
bash_output = Utils.safe_popen_read("#{bin}/vproxy", "bash_completion")
79-
(bash_completion/"vproxy").write bash_output
8084
end
8185
end
8286
end

0 commit comments

Comments
 (0)