Skip to content

Commit

Permalink
* release.yaml: Added comments, removed PR as the trigger
Browse files Browse the repository at this point in the history
  • Loading branch information
hostcc committed Aug 20, 2024
1 parent c81542f commit 29c856c
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
name: release

on:
pull_request:
release:
types: [published]

Expand All @@ -14,14 +13,21 @@ jobs:
- name: Checkout the code
uses: actions/checkout@v4
with:
# Branches/tags should be available for semver action below to pick
# next version
fetch-depth: 0
# Git will use deploy SSH key, mostly to push to default branch being
# protected
ssh-key: ${{ secrets.DEPLOY_KEY }}

- name: Generate next version
id: version
uses: ietf-tools/semver-action@v1
with:
token: ${{ github.token }}
# Pick either current branch for PR or the default branch to find the
# version from (the former is only needed for testing the workflow in
# an PR)
branch: >-
${{
github.head_ref
Expand All @@ -47,5 +53,7 @@ jobs:
- name: Push changes
uses: ad-m/github-push-action@master
with:
# SSH (deploy) key allows to bypass branch protection on default
# branch
ssh: true
branch: ${{ github.event.repository.default_branch }}

0 comments on commit 29c856c

Please sign in to comment.