Skip to content

Fix Duplicate operation Id #42

Fix Duplicate operation Id

Fix Duplicate operation Id #42

name: Java CI with Maven (Push)
on:
push:
branches: [main]
jobs:
check-pr-labels:
runs-on: ubuntu-latest
permissions:
pull-requests: read
outputs:
labels: ${{ steps.get-pr.outputs.pr_labels }}
steps:
- name: Get Pull Request information
uses: 8BitJonny/[email protected]
id: get-pr
build:
runs-on: ubuntu-latest
needs: [check-pr-labels]
if: contains(needs.check-pr-labels.outputs.labels, 'release')
steps:
- uses: actions/checkout@v2
with:
ref: ${{ github.head_ref }}
- name: Set up JDK 11
uses: actions/setup-java@v2
with:
java-version: "11"
distribution: "adopt"
server-id: ossrh
server-username: MAVEN_USERNAME
server-password: MAVEN_CENTRAL_TOKEN
gpg-private-key: ${{ secrets.GPG_SIGNING_KEY }}
gpg-passphrase: MAVEN_GPG_PASSPHRASE
- name: Publish to Maven Central Packages
run: mvn deploy
env:
MAVEN_USERNAME: ${{ secrets.JIRAID }}
MAVEN_CENTRAL_TOKEN: ${{ secrets.JIRAPASS }}
MAVEN_GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }}
- name: Maven version
uses: JActions/[email protected]
id: get-version
- name: Create a Release
uses: marvinpinto/action-automatic-releases@latest
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
automatic_release_tag: ${{ steps.get-version.outputs.version }}
prerelease: false
title: "Release ${{ steps.get-version.outputs.version }}"