aboutsummaryrefslogtreecommitdiff
path: root/goss.rb
diff options
context:
space:
mode:
authorChristian Segundo2023-09-12 17:31:31 +0200
committerChristian Segundo2023-09-12 18:34:04 +0200
commit26487b1400fd8b069f688d73e0d91dde2f4e01f1 (patch)
tree013641bd312628c9a22891fa9c7aee4c7b55caae /goss.rb
parentbcb2fd154d04808c978655d4f9e7a3f1914aeb77 (diff)
downloadhomebrew-tap-26487b1400fd8b069f688d73e0d91dde2f4e01f1.tar.gz
migrate formulae
Diffstat (limited to 'goss.rb')
-rw-r--r--goss.rb21
1 files changed, 21 insertions, 0 deletions
diff --git a/goss.rb b/goss.rb
new file mode 100644
index 0000000..380e8db
--- /dev/null
+++ b/goss.rb
@@ -0,0 +1,21 @@
+class Goss < Formula
+ desc "Quick and Easy server testing/validation"
+ homepage "https://goss.rocks"
+ url "https://github.com/goss-org/goss/archive/refs/tags/v0.3.20.tar.gz"
+ sha256 "5330d62826261533c8b1474799d9bc932fd50977e6f5a193b72244e0aaaf8946"
+ license "Apache-2.0"
+ head "https://github.com/goss-org/goss.git", branch: "master"
+
+ depends_on "go" => [:build]
+
+ def install
+ ldflags = "-s -w"
+ ldflags += if build.head?
+ " -X main.version=#{Utils.git_head}"
+ else
+ " -X main.version=v#{version}"
+ end
+
+ system "go", "build", "-ldflags", ldflags, "-o", bin/"goss", "./cmd/goss"
+ end
+end