Skip to content

Merge pull request #80 from GIScience/fix_publish_action #40

Merge pull request #80 from GIScience/fix_publish_action

Merge pull request #80 from GIScience/fix_publish_action #40

Workflow file for this run

name: Publish to GitHub Packages
on:
push:
branches:
- 'ors_4.0'
release:
types: [ published ]
jobs:
publish:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v2
- name: Set up JDK 17
uses: actions/setup-java@v2
with:
distribution: 'temurin'
java-version: '17'
- name: Cache Maven artifacts
uses: actions/cache@v2
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven-
- name: Cache node
uses: actions/cache@v2
with:
path: web-bundle/node
key: ${{ runner.os }}-node-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os}}-node-
- name: Cache node_modules
uses: actions/cache@v2
with:
path: web-bundle/node_modules
key: ${{ runner.os }}-node-${{ hashFiles('**/pom.xml', '**/package.json') }}
restore-keys: |
${{ runner.os}}-node_modules-
- name: Build and publish package on snapshot
if: github.event_name == 'push' && github.event_name != 'release'
run: |
mvn -B -DskipTests -Pskip-shaded-web-jar -Pskip-tools-jar source:jar deploy
env:
RT_USERNAME: ${{ secrets.RT_USERNAME }}
RT_PASSWORD: ${{ secrets.RT_PASSWORD }}
# Write a task to publish the package to GitHub Packages when a release is published
- name: Build and publish package on release
if: github.event_name == 'release'
run: |
mvn versions:set -DnewVersion=${{ github.event.release.tag_name }} -DgenerateBackupPoms=false
mvn -B -DskipTests -Pskip-shaded-web-jar -Pskip-tools-jar source:jar deploy
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
MAVEN_USERNAME: ${{ secrets.MAVEN_USERNAME }}
MAVEN_PASSWORD: ${{ secrets.MAVEN_PASSWORD }}
MAVEN_REPOSITORY_URL: ${{ secrets.MAVEN_REPOSITORY_URL }}
MAVEN_REPOSITORY_ID: ${{ secrets.MAVEN_REPOSITORY_ID }}
MAVEN_REPOSITORY_NAME: ${{ secrets.MAVEN_REPOSITORY_N

Check failure on line 58 in .github/workflows/push-packages.yml

View workflow run for this annotation

GitHub Actions / Publish to GitHub Packages

Invalid workflow file

The workflow is not valid. .github/workflows/push-packages.yml (Line: 58, Col: 34): The expression is not closed. An unescaped ${{ sequence was found, but the closing }} sequence was not found.