Update en.yml #3
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
name: Release | |
on: | |
push: | |
tags: | |
- 'v*.*.*' | |
permissions: | |
pull-requests: read | |
contents: write | |
jobs: | |
build_release: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
submodules: true | |
- run: git fetch --tags | |
- name: Setup Java | |
uses: actions/setup-java@v4 | |
with: | |
distribution: 'temurin' | |
java-version: '11' | |
- name: Prepare Release Metadata | |
id: release_metadata | |
run: | | |
VERSION=$(echo $GITHUB_REF | cut -d / -f 3) | |
echo "VERSION=$VERSION" >> $GITHUB_OUTPUT | |
echo "RELEASE_NAME=$(echo $VERSION | sed 's/v/V/')" >> $GITHUB_OUTPUT | |
./build/run doc:release_notes -Dcurrent_tag=$VERSION -Doutfile=RELEASE_NOTES.md -Dtoken=${{ secrets.ASPACE_PR_READING_TOKEN }} | |
cat RELEASE_NOTES.md | |
echo "RELEASE_NOTES<<EOF" >> $GITHUB_OUTPUT | |
cat RELEASE_NOTES.md >> $GITHUB_OUTPUT | |
echo "EOF" >> $GITHUB_OUTPUT | |
- name: Build Dist | |
run: ./build/run build-dist -Dversion=${{ steps.release_metadata.outputs.VERSION }} | |
- name: Release | |
uses: softprops/action-gh-release@v1 | |
with: | |
name: ${{ steps.release_metadata.outputs.RELEASE_NAME }} | |
body: ${{ steps.release_metadata.outputs.RELEASE_NOTES }} | |
files: archivesspace-${{ steps.release_metadata.outputs.VERSION }}.zip | |
draft: true |