Skip to content

Merge pull request #217 from awslabs/revert-205-feature/gh-192-gitcommit #7

Merge pull request #217 from awslabs/revert-205-feature/gh-192-gitcommit

Merge pull request #217 from awslabs/revert-205-feature/gh-192-gitcommit #7

Workflow file for this run

name: Release
permissions:
contents: write
on:
push:
tags:
- "v*"
workflow_dispatch:
inputs:
tag:
required: true
type: string
description: Use this existing Git tag to create the release
jobs:
release:
name: Create Release
timeout-minutes: 10
strategy:
matrix:
os: [ ubuntu-22.04 ]
java: [ "11" ]
runs-on: ${{ matrix.os }}
env:
TAG: ${{ github.event.inputs.tag }}
steps:
- name: Checkout repository
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11
- name: Set up JDK ${{ matrix.java }}
uses: actions/setup-java@387ac29b308b003ca37ba93a6cab5eb57c8f5f93
with:
distribution: 'temurin'
java-version: ${{ matrix.java }}
cache: 'maven'
- name: Get short TAG
if: ${{ github.event_name != 'workflow_dispatch' }}
run: |
echo "Retrieving tag from Github ref"
echo "TAG=$(basename "${{ github.ref }}")" >> $GITHUB_ENV
- name: Build JAR artifacts
run: mvn --batch-mode --no-transfer-progress --errors --update-snapshots clean package -Drevision=${TAG}
- name: Create Github Release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
echo "Creating release from tag ${TAG}"
gh release create ${TAG} --generate-notes LICENSE NOTICE THIRD-PARTY-LICENSES README.md target/*.jar target/components/packages/*.zip