Skip to content

5 release ci (#47)

5 release ci (#47) #1

Workflow file for this run

name: Lib Release
on:
push:
tags:
- 'release*'
jobs:
release:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: 17
- uses: actions/cache@v4
with:
path: ~/.m2/repository
key: release_maven
- uses: s4u/maven-settings-action@v3.1.0
with:
servers: '[{"id": "central", "username": "${env.SONATYPE_CENTRAL_USER}", "password": "${env.SONATYPE_CENTRAL_PASS}"}]'
- uses: crazy-max/ghaction-import-gpg@v6
with:
gpg_private_key: ${{ secrets.GPG_PRIVATE_KEY }}
passphrase: ${{ secrets.MAVEN_GPG_PASSPHRASE }}
- name: Release
id: release
env:
MAVEN_GPG_PASSPHRASE: ${{ secrets.MAVEN_GPG_PASSPHRASE }}
SONATYPE_CENTRAL_USER: ${{ secrets.SONATYPE_CENTRAL_USER }}
SONATYPE_CENTRAL_PASS: ${{ secrets.SONATYPE_CENTRAL_PASS }}
run: |
. ./misc/release.sh
echo "new_version=$(cat NEW_VERSION.cache)" >> "$GITHUB_OUTPUT"
- uses: actions/create-github-app-token@v1
id: generate-token
with:
app-id: ${{ secrets.PR_APP_ID }}
private-key: ${{ secrets.PR_APP_PRIVATE_KEY }}
- name: Create Pull Request
uses: peter-evans/create-pull-request@v7
with:
token: ${{ steps.generate-token.outputs.token }}
branch: create-pull-request/bump_version
base: master
delete-branch: true
title: Bump version to ${{ steps.release.outputs.new_version }}
commit-message: |
Bump version to ${{ steps.release.outputs.new_version }}