[ci] publish snapshots with every commit to main (#16)
Adds a workflow for publishing a snapshot to sonatype with each commit to main.
This commit is contained in:
parent
a51f455e33
commit
4cef820c9f
|
@ -0,0 +1,32 @@
|
|||
name: Snapshot Releases
|
||||
|
||||
# Only run on pushes to main:
|
||||
# Replace with 'on: [push]' if you need to run tests on your PR
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
|
||||
jobs:
|
||||
publish:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- name: Set up JDK 21
|
||||
uses: actions/setup-java@v4
|
||||
with:
|
||||
# Modules specify the oldest java version that they support:
|
||||
# even if we build with version 21, produced jars should be compatible with
|
||||
# JVMs running the version specified in each module's maven.compiler.target property
|
||||
java-version: '21'
|
||||
distribution: 'temurin'
|
||||
server-id: ossrh
|
||||
server-username: OSSRH_USERNAME
|
||||
server-password: OSSRH_PASSWORD
|
||||
- name: Publish package
|
||||
env:
|
||||
OSSRH_USERNAME: ${{ secrets.OSSRH_USERNAME }}
|
||||
OSSRH_PASSWORD: ${{ secrets.OSSRH_PASSWORD }}
|
||||
# Notes:
|
||||
# - tests already run in a separate action
|
||||
run: mvn --batch-mode deploy -DskipTests
|
Loading…
Reference in New Issue