Skip to content
This repository has been archived by the owner on Apr 4, 2024. It is now read-only.

DRAFT Publish github maven package #1

DRAFT Publish github maven package

DRAFT Publish github maven package #1

name: Publish github maven package
on:
workflow_dispatch:
jobs:
build-package:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- name: disable workflow
run: |
false
- name: get env data
run: |
echo "********************** STANDARD ENV VARIABLES ********************"
env
echo ""
echo "********************** GITHUB EVENT json *************************"
echo "${GITHUB_CONTEXT}" | jq '.'
false
env:
GITHUB_CONTEXT: ${{ toJson(github) }}
- uses: actions/checkout@v3
- name: Set up JDK 11
uses: actions/setup-java@v3
with:
java-version: '11'
distribution: 'temurin'
server-id: github
settings-path: ${{ github.workspace }}
- name: Build with Maven
run: mvn -B package --file pom.xml
- name: Publish maven package to GitHub Packages
run: mvn deploy -s $GITHUB_WORKSPACE/settings.xml
env:
# GITHUB_TOKEN: ${{ github.token }}
GITHUB_TOKEN: ${{ secrets.PKG_PUSH_TOKEN }}