Skip to content

Chore: a new github action #2

Chore: a new github action

Chore: a new github action #2

Workflow file for this run

name: rc-release
on:
push:
tags:
- v*
jobs:
check-tag:
runs-on: ubuntu-latest
outputs:
proceed: ${{ steps.tag-checker.outputs.proceed }}
steps:
- name: Check for RC in tag
id: tag-checker
run: |
if [[ "${GITHUB_REF##*/}" == *"-rc"* ]]; then
echo "RC tag detected: ${GITHUB_REF##*/}"
echo "proceed=true" >> $GITHUB_ENV
echo "::set-output name=proceed::true"
else
echo "proceed=false" >> $GITHUB_ENV
echo "::set-output name=proceed::false"
fi
release:
needs: check-tag
runs-on: ubuntu-latest
steps:
- name: checkout code
uses: actions/checkout@v2
with:
submodules: "true"
- run: git fetch --prune --unshallow
- name: setup dependencies
uses: actions/setup-go@v2
- name: release dry run
run: |
make release-candidate-dry-run
- name: setup release environment
run: |
echo "GITHUB_TOKEN=${{ secrets.PUBLISHER_TOKEN }}" >> .release-env
env:
HOMEBREW_APP_NAME: ${{ env.HOMEBREW_APP_NAME }}
- name: release publish
run: |
make release-candidate