aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Ashcon Partovi <ashcon@partovi.net> 2023-02-01 11:33:08 -0800
committerGravatar Ashcon Partovi <ashcon@partovi.net> 2023-02-01 11:33:08 -0800
commit0c3e55132c303951233fb290e0fce8b87dd1e02c (patch)
tree096a211a3cb680e00bc7ca58d9fd7bf8f5e8e867
parentc69bbbd24ff822b7df6fc01e6c668cb6a38c9f8a (diff)
downloadbun-0c3e55132c303951233fb290e0fce8b87dd1e02c.tar.gz
bun-0c3e55132c303951233fb290e0fce8b87dd1e02c.tar.zst
bun-0c3e55132c303951233fb290e0fce8b87dd1e02c.zip
Update homebrew release action
-rw-r--r--.github/workflows/bun-homebrew.yml30
-rw-r--r--.github/workflows/bun-release.yml29
2 files changed, 29 insertions, 30 deletions
diff --git a/.github/workflows/bun-homebrew.yml b/.github/workflows/bun-homebrew.yml
deleted file mode 100644
index 49501c1cc..000000000
--- a/.github/workflows/bun-homebrew.yml
+++ /dev/null
@@ -1,30 +0,0 @@
-name: bun-homebrew
-on:
- release:
- types:
- - published
- - edited
-jobs:
- homebrew:
- runs-on: ubuntu-latest
- if: github.repository_owner == 'oven-sh' && github.event.release.published_at != null
- steps:
- - id: checkout
- name: Checkout
- uses: actions/checkout@v3
- with:
- repository: oven-sh/homebrew-bun
- token: ${{ env.HOMEBREW_TOKEN }}
- - id: setup-ruby
- name: Setup Ruby
- uses: ruby/setup-ruby@v1
- with:
- ruby-version: '2.6'
- - id: update-tap
- name: Update Tap
- run: ruby scripts/release.rb "${{ github.event.release.tag_name }}"
- - id: commit-tap
- name: Commit Tap
- uses: stefanzweifel/git-auto-commit-action@v4
- with:
- commit_message: Release ${{ github.event.release.tag_name }}
diff --git a/.github/workflows/bun-release.yml b/.github/workflows/bun-release.yml
index 5bf4fe6dc..0a84b0d44 100644
--- a/.github/workflows/bun-release.yml
+++ b/.github/workflows/bun-release.yml
@@ -91,3 +91,32 @@ jobs:
push: true
tags: ${{ steps.metadata.outputs.tags }}
labels: ${{ steps.metadata.outputs.labels }}
+ homebrew:
+ name: Release to Homebrew
+ runs-on: ubuntu-latest
+ steps:
+ - id: checkout
+ name: Checkout
+ uses: actions/checkout@v3
+ with:
+ repository: oven-sh/homebrew-bun
+ - id: environment
+ name: Setup Environment
+ run: |
+ TAG="${{ github.event.inputs.tag }}"
+ TAG="${TAG:-"${{ github.event.release.tag_name }}"}"
+ echo "Setup tag: ${TAG}"
+ echo "TAG=${TAG}" >> ${GITHUB_ENV}
+ - id: setup-ruby
+ name: Setup Ruby
+ uses: ruby/setup-ruby@v1
+ with:
+ ruby-version: "2.6"
+ - id: update-tap
+ name: Update Tap
+ run: ruby scripts/release.rb "${{ env.TAG }}"
+ - id: commit-tap
+ name: Commit Tap
+ uses: stefanzweifel/git-auto-commit-action@v4
+ with:
+ commit_message: Release ${{ env.TAG }}