Skip to content

Release

Release #5

Workflow file for this run

name: Release
on:
workflow_dispatch:
inputs:
release_version:
description: 'Release version'
required: true
next_version:
description: 'Next version to set after release (without -SNAPSHOT)'
required: true
jobs:
release-job:
permissions:
# For creating releases
contents: write
env:
RELEASE_VERSION: ${{ inputs.release_version }}
NEXT_VERSION: ${{ inputs.next_version }}
runs-on: ubuntu-latest
steps:
- name: Checkout sources
uses: actions/checkout@v4
- name: Setup Java
uses: ./.github/actions/setup_java
- name: Update version to stable
shell: bash
run: |
git config --global user.name "${GITHUB_ACTOR}"
git config --global user.email "${GITHUB_ACTOR}@users.noreply.github.com"
./mvnw tycho-versions:set-version -DnewVersion=$RELEASE_VERSION
git add -u
git commit -m "Prepare for release v$RELEASE_VERSION"
git tag v$RELEASE_VERSION
- name: Build
uses: ./.github/actions/build
- name: Push release tag
shell: bash
run: |
git push origin main v$RELEASE_VERSION
- name: Publish release
uses: softprops/action-gh-release@de2c0eb89ae2a093876385947365aca7b0e5f844 # v1
with:
tag_name: v${{ inputs.release_version }}
generate_release_notes: true
draft: true
files: |
MatCalciteRepository/target/MatCalciteRepository*.zip
- name: Publish Eclipse update site
if: github.repository == 'vlsi/mat-calcite-plugin'
uses: ./.github/actions/publish-update-site
with:
update_site_token:
${{ secrets.UPDATE_SITE_TOKEN }}
- name: Prepare for next development iteration
shell: bash
run: |
./mvnw tycho-versions:set-version -DnewVersion=$NEXT_VERSION-SNAPSHOT
git add -u
git commit -m "Update version to $NEXT_VERSION-SNAPSHOT"
git push origin main v$RELEASE_VERSION