Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Publish to Package Managers | |
| on: | |
| workflow_dispatch: | |
| release: | |
| types: [published] | |
| jobs: | |
| # Update Homebrew formula (macOS/Linux) | |
| homebrew: | |
| name: Update Homebrew | |
| if: github.repository_owner == 'go-nv' | |
| strategy: | |
| matrix: | |
| os: ["ubuntu-latest"] | |
| runs-on: ${{ matrix.os }} | |
| steps: | |
| - uses: actions/checkout@v5 | |
| with: | |
| token: ${{ secrets.GH_TOKEN }} | |
| - name: Set up Go | |
| uses: actions/setup-go@v5 | |
| with: | |
| go-version: "stable" | |
| - name: Build goenv | |
| run: make build | |
| - name: Add goenv to PATH | |
| run: echo "${GITHUB_WORKSPACE}" >> $GITHUB_PATH | |
| - name: Create Homebrew PR | |
| uses: dawidd6/action-homebrew-bump-formula@v5 | |
| with: | |
| # Required, custom GitHub access token with the 'public_repo' and 'workflow' scopes | |
| token: ${{ secrets.GH_HOMEBREW_TOKEN }} | |
| # Optional, will create tap repo fork in organization | |
| # org: ORG | |
| # Optional, use the origin repository instead of forking | |
| no_fork: false | |
| # Formula name, required | |
| formula: goenv | |
| # Optional, will be determined automatically | |
| tag: ${{github.ref}} | |
| # Optional, will be determined automatically | |
| revision: ${{github.sha}} | |
| # Optional, if don't want to check for already open PRs | |
| force: true # true |