22 lines
850 B
YAML
22 lines
850 B
YAML
name: Publish artifact to maven repository workflow
|
|
on:
|
|
workflow_call:
|
|
jobs:
|
|
publish_maven:
|
|
name: Publish distribution
|
|
runs-on: docker-ubuntu
|
|
steps:
|
|
- name: Checkout source code
|
|
uses: actions/checkout@v4
|
|
with:
|
|
token: ${{ secrets.GIT_ACCESS_TOKEN }}
|
|
submodules: 'true'
|
|
- name: Setup java runtime
|
|
uses: actions/setup-java@v4
|
|
with:
|
|
distribution: 'zulu'
|
|
java-version: ${{ vars.JAVA_VERSION }}
|
|
- name: Publish to maven
|
|
run: |
|
|
echo "Publis target URL: ${{ gitea.server_url }}/api/packages/${{ gitea.repository_owner }}/maven"
|
|
./gradlew publish -PMAVEN_PUBLISH_ACCESS_TOKEN=${{ secrets.GIT_ACCESS_TOKEN }} -PMAVEN_PUBLISH_REPOSITORY_URL="${{ gitea.server_url }}/api/packages/${{ gitea.repository_owner }}/maven" |