add publish artifact

This commit is contained in:
2025-09-07 00:04:46 +02:00
parent cef8b710c7
commit d0c7f47441
2 changed files with 38 additions and 0 deletions

View File

@@ -0,0 +1,36 @@
name: Publish Artifact
on:
workflow_call:
inputs:
JAVA_VERSION:
description: Java version to use
required: false
type: string
default: '17'
BRANCH_REFERENCE:
description: Branch reference
required: true
type: string
jobs:
publish-artifact:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 1
ref: ${{ inputs.BRANCH_REFERENCE }}
token: ${{ secrets.CI_BOT_TOKEN }}
- name: Set up JDK
uses: actions/setup-java@v4
with:
distribution: temurin
java-version: ${{ inputs.JAVA_VERSION }}
- name: Run Gradle
run: ./gradlew publishAllPublicationsToGiteaPackagesRepository
shell: bash
env:
REPOSITORY_USER: ${{ secrets.CI_BOT_USERNAME }}
REPOSITORY_TOKEN: ${{ secrets.CI_BOT_TOKEN }}

View File

@@ -1,5 +1,7 @@
# Common Workflows.
Rules and stuff say keep workflow in `/.gite/workflow` look at `/.gite/actions` later on.
## Actions secrets and variables.
### Secrets