diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index 074e268..cf81795 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -52,6 +52,11 @@ on: type: string default: "" description: "Path to a custom WXS file in the caller repo for MSI generation (relative to repo root). If not provided, uses default template." + brew: + required: false + type: boolean + default: true + description: "Whether to publish a Homebrew formula to the public conductorone/homebrew-baton tap." secrets: RELENG_GITHUB_TOKEN: required: true @@ -260,6 +265,7 @@ jobs: working-directory: _workflows env: REPO_NAME: ${{ github.event.repository.name }} + BREW_SKIP_UPLOAD: ${{ inputs.brew != true }} # For provenance predicate template WORKFLOWS_REF: ${{ needs.determine-workflows-ref.outputs.ref }} RELEASE_TAG: ${{ inputs.tag }} diff --git a/README.md b/README.md index 34d831d..f60b163 100644 --- a/README.md +++ b/README.md @@ -82,6 +82,7 @@ The release workflow accepts the following input parameters: | `docker_extra_files` | No | `""` | Comma-separated list of extra files/dirs to include in Docker build context | | `msi` | No | `true` | Whether to build MSI Windows installers | | `msi_wxs_path` | No | `""` | Path to custom WXS template for MSI installer (uses default if not set) | +| `brew` | No | `true` | Whether to publish a Homebrew formula to the public `conductorone/homebrew-baton` tap | 2. Ensure your repository has the following secrets configured: diff --git a/templates/.goreleaser-binaries-template.yaml.tmpl b/templates/.goreleaser-binaries-template.yaml.tmpl index df5cb0b..da6f509 100644 --- a/templates/.goreleaser-binaries-template.yaml.tmpl +++ b/templates/.goreleaser-binaries-template.yaml.tmpl @@ -92,6 +92,7 @@ brews: owner: conductorone name: homebrew-baton directory: Formula + skip_upload: "${BREW_SKIP_UPLOAD}" homepage: https://conductorone.com test: | system "#{bin}/${REPO_NAME} -v"