homebrew-core/Formula/warp.rb
Stanislas POLU 0ccae27e54 warp 0.0.3 (new formula)
Closes #13677.

Signed-off-by: FX Coudert <fxcoudert@gmail.com>
2017-05-20 20:35:59 +02:00

25 lines
794 B
Ruby

class Warp < Formula
desc "Secure terminal sharing with one simple command"
homepage "https://github.com/spolu/warp"
url "https://github.com/spolu/warp/archive/v0.0.3.tar.gz"
sha256 "9079899099b63ee470e693b7f2723cbf8d75cafe880b4329cf9f516c2669e8ca"
depends_on "go" => :build
def install
ENV["GOPATH"] = buildpath
mkdir_p buildpath/"src/github.com/spolu/"
ln_sf buildpath, buildpath/"src/github.com/spolu/warp"
system "go", "build", "-o", "#{bin}/warp", "github.com/spolu/warp/client/cmd/warp"
end
test do
rand_id = (0...16).map { ("a".."z").to_a[rand(26)] }.join
out = shell_output("#{bin}/warp connect test-#{rand_id}")
assert_match /Connected to warp:/, out
assert_match /(Received warp_unknown|Not running in a terminal)/, out
end
end