From 3ba8014cdfb7d24f8483441923e678d74cfc7307 Mon Sep 17 00:00:00 2001 From: authzedbot Date: Wed, 31 Jul 2024 09:21:46 -0400 Subject: [PATCH] Brew formula update for spicedb version v1.35.1 --- Formula/spicedb@1.35.1.rb | 84 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 84 insertions(+) create mode 100644 Formula/spicedb@1.35.1.rb diff --git a/Formula/spicedb@1.35.1.rb b/Formula/spicedb@1.35.1.rb new file mode 100644 index 0000000..1bb9495 --- /dev/null +++ b/Formula/spicedb@1.35.1.rb @@ -0,0 +1,84 @@ +# typed: false +# frozen_string_literal: true + +# This file was generated by GoReleaser. DO NOT EDIT. +class SpicedbAT1351 < Formula + desc "Google Zanzibar-inspired permissions database for fine-grained access control" + homepage "https://github.com/authzed/spicedb" + version "1.35.1" + license "Apache-2.0" + + depends_on "go" => :build + + on_macos do + on_intel do + url "https://github.com/authzed/spicedb/releases/download/v1.35.1/spicedb_1.35.1_darwin_amd64.tar.gz" + sha256 "f568d0fdb4d0b8363a7f43b1c2884041160bc6f3beae35aba2bd43ccc4b47492" + + def install + if build.head? + versionVar = "github.com/jzelinskie/cobrautil/v2.Version" + versionCmd = "$(git describe --always --abbrev=7 --dirty --tags)" + system "go build --ldflags '-s -w -X #{versionVar}=#{versionCmd}' ./cmd/spicedb" + end + bin.install "spicedb" + generate_completions_from_executable(bin/"spicedb", "completion", shells: [:bash, :zsh, :fish]) + end + end + on_arm do + url "https://github.com/authzed/spicedb/releases/download/v1.35.1/spicedb_1.35.1_darwin_arm64.tar.gz" + sha256 "89b191dc15712728317f7c848997c882724129e12a455cc3e9be4a103b01da29" + + def install + if build.head? + versionVar = "github.com/jzelinskie/cobrautil/v2.Version" + versionCmd = "$(git describe --always --abbrev=7 --dirty --tags)" + system "go build --ldflags '-s -w -X #{versionVar}=#{versionCmd}' ./cmd/spicedb" + end + bin.install "spicedb" + generate_completions_from_executable(bin/"spicedb", "completion", shells: [:bash, :zsh, :fish]) + end + end + end + + on_linux do + on_intel do + if Hardware::CPU.is_64_bit? + url "https://github.com/authzed/spicedb/releases/download/v1.35.1/spicedb_1.35.1_linux_amd64.tar.gz" + sha256 "d13405411528337647011ef99e8e44f30b4c8493f50abd69f1082ea4bad76402" + + def install + if build.head? + versionVar = "github.com/jzelinskie/cobrautil/v2.Version" + versionCmd = "$(git describe --always --abbrev=7 --dirty --tags)" + system "go build --ldflags '-s -w -X #{versionVar}=#{versionCmd}' ./cmd/spicedb" + end + bin.install "spicedb" + generate_completions_from_executable(bin/"spicedb", "completion", shells: [:bash, :zsh, :fish]) + end + end + end + on_arm do + if Hardware::CPU.is_64_bit? + url "https://github.com/authzed/spicedb/releases/download/v1.35.1/spicedb_1.35.1_linux_arm64.tar.gz" + sha256 "bd3aebe5f399fd1fa746f826f52839dc63ebf86418713ade5390ee946c62898d" + + def install + if build.head? + versionVar = "github.com/jzelinskie/cobrautil/v2.Version" + versionCmd = "$(git describe --always --abbrev=7 --dirty --tags)" + system "go build --ldflags '-s -w -X #{versionVar}=#{versionCmd}' ./cmd/spicedb" + end + bin.install "spicedb" + generate_completions_from_executable(bin/"spicedb", "completion", shells: [:bash, :zsh, :fish]) + end + end + end + end + + head "https://github.com/authzed/spicedb.git", :branch => "main" + + test do + system "#{bin}/spicedb version" + end +end