chore(aptos): Release aptos-v1.1.1
#104
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Workflow to create a new tag release when a release branch is merged | |
# | |
# The `ci-workflows` tag release action can be found at https://github.com/argumentcomputer/ci-workflows/blob/main/.github/actions/tag-release/action.yml | |
name: Tag release | |
on: | |
pull_request: | |
types: [ closed ] | |
branches: | |
- release/* | |
workflow_dispatch: | |
inputs: | |
light-client: | |
description: 'Light client to release' | |
type: 'string' | |
required: true | |
release-branch: | |
description: 'Branch to release' | |
type: 'string' | |
required: true | |
version: | |
description: 'SemVer release version, e.g. `1.0.0`' | |
type: 'string' | |
required: true | |
jobs: | |
tag-bump: | |
if: | | |
(github.event.pull_request.merged == true && | |
(startsWith(github.event.pull_request.head.ref, 'release-pr') || | |
startsWith(github.event.pull_request.head.ref, 'patch/'))) || | |
github.event_name == 'workflow_dispatch' | |
runs-on: ubuntu-latest | |
steps: | |
- name: Git config | |
run: | | |
git config --global user.name "github-actions[bot]" | |
git config --global user.email "github-actions[bot]@users.noreply.github.com" | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- uses: actions/checkout@v4 | |
with: | |
repository: argumentcomputer/ci-workflows | |
path: ci-workflows | |
- name: Get branch and version info | |
run: | | |
if [[ "${{ github.event_name }}" == "pull_request" ]]; then | |
RELEASE_BRANCH=${{ github.event.pull_request.base.ref }} | |
# Get tag and version from PR title | |
TAG=$(echo '${{ github.event.pull_request.title }}' | awk '/Release/ {print $NF}' | tr -d '`') | |
LIGHT_CLIENT=${TAG%%-v*} | |
VERSION="${TAG#*-v}" | |
else | |
LIGHT_CLIENT=${{ inputs.light-client }} | |
RELEASE_BRANCH=${{ inputs.release-branch }} | |
VERSION=${{ inputs.version }} | |
fi | |
echo "LIGHT_CLIENT=$LIGHT_CLIENT" | tee -a $GITHUB_ENV | |
echo "RELEASE_BRANCH=$RELEASE_BRANCH" | tee -a $GITHUB_ENV | |
echo "VERSION=$VERSION" | tee -a $GITHUB_ENV | |
- name: Publish release | |
uses: ./ci-workflows/.github/actions/tag-release | |
with: | |
release-branch: ${{ env.RELEASE_BRANCH }} | |
version: ${{ env.VERSION }} | |
tag-prefix: ${{ env.LIGHT_CLIENT }} | |
changelog-config-file: ${{ github.workspace }}/.github/changelog-config.json |