Skip to content

Commit

Permalink
Merge pull request #71 from edmcouncil/70-switch-to-github-actions-up…
Browse files Browse the repository at this point in the history
…load-assets

Add GitHub Actions - upload-assets
  • Loading branch information
mereolog authored Mar 22, 2024
2 parents 2603921 + b1f6ba9 commit 35bfb5d
Showing 1 changed file with 37 additions and 0 deletions.
37 changes: 37 additions & 0 deletions .github/workflows/upload-assets.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: upload-assets

on:
push:
tags:
- "*"

env:
ASSET: rdf-toolkit.jar

jobs:
build:
runs-on: ubuntu-latest
steps:
-
name: Checkout
uses: actions/checkout@v4
-
name: Set up JDK
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: '21'
-
name: Run the Maven verify phase
run: mvn --batch-mode --update-snapshots verify
-
name: Get JAR filename
run: echo "FILENAME=$(mvn -q exec:exec -Dexec.executable='echo' -Dexec.args='${project.build.directory}/${project.build.finalName}.${project.packaging}' -DforceStdout)" >> "$GITHUB_ENV"
-
name: Copy JAR as "${{ env.ASSET }}"
run: cp -avf "${FILENAME}" "${{ env.ASSET }}"
-
name: Upload "${{ env.ASSET }}"
run: gh release upload "${{ github.ref_name }}" "${{ env.ASSET }}"
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 comments on commit 35bfb5d

Please sign in to comment.