Skip to content

Master release

Master release #17

Workflow file for this run

name: Master release
on:
workflow_dispatch:
inputs:
releaseVersion:
description: 'Release and tag version (ie 5.5.0)'
required: true
developmentVersion:
decription: 'Next development version, with SNAPSHOT'
required: true
jobs:
master_release:
if: "!contains(github.event.head_commit.message, '[maven-release-plugin]')"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up JDK 11
uses: actions/setup-java@v4
with:
java-version: '11'
distribution: 'temurin'
- name: Initialize mandatory git config
run: |
git config user.name "GitHub Actions"
git config user.email [email protected]
- name: ssh-agent
uses: webfactory/[email protected]
with:
ssh-private-key: ${{ secrets.SSH_KEY }}
- name: Release with Maven
env:
GITHUB_USERNAME: ${{ github.actor }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GH_PACKAGE_REPO_PASSWORD: ${{ secrets.GH_PACKAGE_REPO_PASSWORD }}
run: |
mvn -B -Dtag=${{ github.event.inputs.releaseVersion }} release:prepare \
-DreleaseVersion=${{ github.event.inputs.releaseVersion }} \
-DdevelopmentVersion=${{ github.event.inputs.developmentVersion }} --file pom.xml \
&& mvn release:perform -B --file pom.xml
- name: Create A Pull Request
uses: thomaseizinger/[email protected]
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
head: master
base: develop
title: Released master into develop
body: |
Hi!
This PR was created in response workflow running.
I've updated the version name and code commit: ${{ steps.make-commit.outputs.commit }}.