Files

35 lines
998 B
YAML
Raw Permalink Normal View History

2020-02-20 12:44:22 -05:00
# This workflow will build a package using Maven and then publish it to GitHub packages when a release is created
2021-04-05 17:44:33 +03:00
# For more information see: https://github.com/actions/setup-java/blob/main/docs/advanced-usage.md#apache-maven-with-a-settings-path
2020-02-20 11:33:16 -05:00
name: Maven Package
on:
release:
types: [created]
jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
2020-02-20 11:33:16 -05:00
steps:
- uses: actions/checkout@v2
- name: Set up JDK 11
uses: actions/setup-java@v2
2020-02-20 11:33:16 -05:00
with:
java-version: '11'
2021-03-11 12:56:09 +03:00
distribution: 'adopt'
2020-02-20 11:33:16 -05:00
server-id: github # Value of the distributionManagement/repository/id field of the pom.xml
settings-path: ${{ github.workspace }} # location for the settings.xml file
- name: Build with Maven
run: mvn -B package --file pom.xml
- name: Publish to GitHub Packages Apache Maven
run: mvn deploy -s $GITHUB_WORKSPACE/settings.xml
env:
2021-04-05 17:44:33 +03:00
GITHUB_TOKEN: ${{ github.token }}