Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 11 additions & 2 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,20 @@ on:
release:
types: [published]
workflow_dispatch:
inputs:
publish:
description: Publish to Maven Central after validation
required: true
type: boolean
default: false

permissions:
contents: read

jobs:
maven-central:
name: Publish to Maven Central
runs-on: ubuntu-latest
runs-on: [self-hosted, Linux, X64, nvoip-ci-public-release]
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
Expand All @@ -23,7 +29,10 @@ jobs:
server-password: MAVEN_CENTRAL_TOKEN
gpg-private-key: ${{ secrets.MAVEN_GPG_PRIVATE_KEY }}
gpg-passphrase: MAVEN_GPG_PASSPHRASE
- run: mvn --batch-mode deploy -P release
- if: github.event_name != 'release' && !inputs.publish
run: mvn --batch-mode verify
- if: github.event_name == 'release' || inputs.publish
run: mvn --batch-mode deploy -P release
env:
MAVEN_CENTRAL_USERNAME: ${{ secrets.MAVEN_CENTRAL_USERNAME }}
MAVEN_CENTRAL_TOKEN: ${{ secrets.MAVEN_CENTRAL_TOKEN }}
Expand Down
Loading