Skip to content

Commit

Permalink
ci: release canary by dispatch (web-infra-dev#6502)
Browse files Browse the repository at this point in the history
  • Loading branch information
LingyuCoder authored May 10, 2024
1 parent 71ff0a7 commit 839be04
Showing 1 changed file with 8 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,12 @@
name: Release Canary

on:
issue_comment:
types: [created]
workflow_dispatch:
inputs:
commit:
required: true
type: string
description: "Commit SHA"

jobs:
get-runner-labels:
Expand All @@ -14,7 +18,6 @@ jobs:
build:
name: Build Canary
needs: [get-runner-labels]
if: github.event.issue.pull_request && contains(github.event.comment.body, '!canary')
strategy:
fail-fast: false # Build and test everything so we can look at all the errors
matrix:
Expand All @@ -39,7 +42,7 @@ jobs:
runner: ${{ needs.get-runner-labels.outputs.MACOS_RUNNER_LABELS }}
uses: ./.github/workflows/reusable-build.yml
with:
ref: refs/pull/${{ github.event.issue.number }}/head
ref: ${{inputs.commit}}
target: ${{ matrix.array.target }}
runner: ${{ matrix.array.runner }}
test: false
Expand All @@ -53,7 +56,7 @@ jobs:
uses: actions/checkout@v4
with:
fetch-depth: 1
ref: refs/pull/${{ github.event.issue.number }}/head
ref: ${{inputs.commit}}

- name: Pnpm Cache
uses: ./.github/actions/pnpm-cache
Expand Down Expand Up @@ -82,14 +85,3 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
REPOSITORY: ${{ github.repository }}
PULL_REQUEST_NUMBER: ${{ github.event.issue.number }}
COMMENT: ${{ toJson(github.event.comment) }}

- name: Write a new comment
uses: peter-evans/create-or-update-comment@v4
continue-on-error: true
with:
issue-number: ${{ github.event.issue.number }}

body-path: 'version_output'

0 comments on commit 839be04

Please sign in to comment.