Skip to content

Commit

Permalink
ci(release): Add support for release via getsentry/publish repo (#3124)
Browse files Browse the repository at this point in the history
Same as getsentry/symbolicator#319.

#skip-changelog
  • Loading branch information
BYK authored Dec 16, 2020
1 parent 7710945 commit dfa97e4
Show file tree
Hide file tree
Showing 2 changed files with 42 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .craft.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
minVersion: '0.13.2'
minVersion: '0.14.0'
github:
owner: getsentry
repo: sentry-javascript
Expand Down
41 changes: 41 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: release
on:
workflow_dispatch:
inputs:
version:
description: Version to release
required: true
force:
description: Force a release even when there are release-blockers (optional)
required: false
jobs:
release:
runs-on: ubuntu-latest
name: 'Release a new version'
steps:
- name: Prepare release
uses: getsentry/action-prepare-release@main
with:
version: ${{ github.event.inputs.version }}
force: ${{ github.event.inputs.force }}
- uses: actions/checkout@v2
with:
token: ${{ secrets.GH_RELEASE_PAT }}
fetch-depth: 0
- uses: getsentry/craft@master
name: Craft Prepare
with:
action: prepare
version: ${{ env.RELEASE_VERSION }}
- name: Request publish
if: success()
uses: actions/github-script@v3
with:
github-token: ${{ secrets.GH_RELEASE_PAT }}
script: |
const repoInfo = context.repo;
await github.issues.create({
owner: repoInfo.owner,
repo: 'publish',
title: `publish: ${repoInfo.repo}@${process.env.RELEASE_VERSION}`,
});

0 comments on commit dfa97e4

Please sign in to comment.