1name: Release Candidate Automation 2 3on: 4 workflow_dispatch: 5 inputs: 6 commit_id: 7 description: 'Commit ID to tag' 8 required: true 9 version_number: 10 description: 'Release Version Number (Eg, v1.0.0-rc1)' 11 required: true 12 13jobs: 14 tag-commit: 15 name: Tag commit 16 runs-on: ubuntu-latest 17 steps: 18 - name: Checkout code 19 uses: actions/checkout@v2 20 with: 21 ref: ${{ github.event.inputs.commit_id }} 22 - name: Configure git identity 23 run: | 24 git config --global user.name ${{ github.actor }} 25 git config --global user.email ${{ github.actor }}@users.noreply.github.com 26 - name: Tag Commit and Push to Remote 27 run: | 28 git tag ${{ github.event.inputs.version_number }} -a -m "FreeRTOS-Plus-TCP Library ${{ github.event.inputs.version_number }}" 29 git push origin --tags 30 - name: Verify tag on remote 31 run: | 32 git tag -d ${{ github.event.inputs.version_number }} 33 git remote update 34 git checkout tags/${{ github.event.inputs.version_number }} 35 git diff ${{ github.event.inputs.commit_id }} tags/${{ github.event.inputs.version_number }} 36