Skip to content

release

release #5

Workflow file for this run

name: release
on:
push:
tags: ['v*.*.*']
jobs:
release:
name: Release
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
ref: master
- run: git fetch --tags
- name: check branch
run: |
br="$(git branch --contains $GITHUB_REF --format '%(refname:short)' master)"
if [[ "$br" != "master" ]]; then
echo "$br != master"
exit 1
fi
- name: Test
uses: ./.github/actions/test
- name: release-notes
run: 'echo "$(git tag -l --format="%(contents:body)" $GITHUB_REF_NAME)" > RELEASE_NOTES'
- name: version
id: version
run: 'git describe --always --dirty $GITHUB_REF_NAME | sed "s/^v//"'
- uses: actions/create-release@v1
id: create_release
with:
draft: false
prerelease: false
release_name: ${{ steps.version.outputs.version }}
tag_name: ${{ github.ref }}
body_path: RELEASE_NOTES
env:
GITHUB_TOKEN: ${{ github.token }}