提交 b0d60941 编写于 作者: J Jingwen Owen Ou

Adapt to amd64 or 386 in brew script

上级 b9504d1b
......@@ -2,11 +2,15 @@ require 'formula'
class Gh < Formula
VERSION = '0.0.1'
ARCH = if MacOS.prefer_64_bit?
'amd64'
else
'386'
end
homepage 'https://github.com/jingweno/gh'
url "https://drone.io/github.com/jingweno/gh/files/target/#{VERSION}-snapshot/darwin_amd64/gh_#{VERSION}-snapshot_darwin_amd64.zip"
version VERSION
sha1 '12743626cd717014c3ddd8ac70d77da44356fa66'
url "https://drone.io/github.com/jingweno/gh/files/target/#{VERSION}-snapshot/darwin_#{ARCH}/gh_#{VERSION}-snapshot_darwin_#{ARCH}.tar.gz"
head 'https://github.com/jingweno/gh.git'
def install
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册