Skip to content

Perform release from latest tag #34

Perform release from latest tag

Perform release from latest tag #34

Workflow file for this run

---
name: ci
run-name: Perform release from latest tag
permissions:
contents: write
on:
push:
tags: ['*']
jobs:
release:
name: Create a GitHub release
runs-on: ubuntu-latest
steps:
- name: Checkout main
uses: actions/checkout@v3
with:
fetch-depth: 0
- run: >-
git config user.name github-actions;
git config user.email [email protected];
git config --global user.email [email protected];
git config --global user.name github-actions;
- name: Fetch latest tag
run: >-
echo "LATEST_TAG=$(git describe --tags `git rev-list --tags --max-count=1`)"
>> "$GITHUB_ENV"
- name: SemVer release
uses: cocogitto/[email protected]
id: relase
- name: Generate changelog
run: >-
cog changelog --at ${{env.LATEST_TAG }} --template
remote > GITHUB_CHANGELOG.md
- name: print
run: echo ${{ env.LATEST_TAG }}
- name: Upload github release
uses: softprops/action-gh-release@v1
with:
body_path: GITHUB_CHANGELOG.md
tag_name: ${{ env.LATEST_TAG }}