Skip to content

Merge pull request #296 from thefrontside/cl/tag-match-on-publish #10

Merge pull request #296 from thefrontside/cl/tag-match-on-publish

Merge pull request #296 from thefrontside/cl/tag-match-on-publish #10

name: Version Or Release
on:
push:
branches:
- main
jobs:
version-or-publish:
runs-on: ubuntu-latest
timeout-minutes: 65
steps:
- uses: actions/checkout@v4
with:
token: ${{ secrets.FRONTSIDEJACK_GITHUB_TOKEN }}
fetch-depth: 0 # required for use of git history
- uses: actions/setup-node@v3
with:
registry-url: "https://registry.npmjs.org"
- name: Commit Signing
uses: crazy-max/ghaction-import-gpg@v6
with:
gpg_private_key: ${{ secrets.FRONTSIDEJACK_GPG_KEY }}
passphrase: ${{ secrets.FRONTSIDEJACK_GPG_KEY_PASSPHRASE }}
git_user_signingkey: true
git_commit_gpgsign: true
- name: covector version or publish (publish when no change files present)
uses: jbolda/covector/packages/[email protected]
id: covector
with:
token: ${{ secrets.FRONTSIDEJACK_GITHUB_TOKEN }}
command: "version-or-publish"
recognizeContributors: true
- name: Create Pull Request With Versions Bumped
uses: peter-evans/create-pull-request@v6
if: steps.covector.outputs.commandRan == 'version'
with:
token: ${{ secrets.FRONTSIDEJACK_GITHUB_TOKEN }}
title: "Publish New Versions"
author: Jack <[email protected]>
committer: Jack <[email protected]>
commit-message: "publish new versions"
labels: "version updates"
branch: "release"
body: ${{ steps.covector.outputs.change }}
- name: Push Git Tags
# through the actions/checkout token, this will use the frontsidejack token
if: steps.covector.outputs.commandRan == 'publish'
run: git push --tags