From 43fea4753295703329e649be9d6a38c174b3912b Mon Sep 17 00:00:00 2001 From: Konloch Date: Fri, 23 Jul 2021 18:34:30 -0700 Subject: [PATCH] Update maven.yml --- .github/workflows/maven.yml | 18 +++++++++++++----- 1 file changed, 13 insertions(+), 5 deletions(-) diff --git a/.github/workflows/maven.yml b/.github/workflows/maven.yml index 8386783c..f769a0a8 100644 --- a/.github/workflows/maven.yml +++ b/.github/workflows/maven.yml @@ -1,13 +1,12 @@ -# This workflow will build a Java project with Maven -# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-maven +# This will build the BCV repo and upload the package as an artifact -name: Java CI with Maven +name: Build BCV on: push: - branches: [ master ] + branches: [ main ] pull_request: - branches: [ master ] + branches: [ main ] jobs: build: @@ -23,3 +22,12 @@ jobs: distribution: 'adopt' - name: Build with Maven run: mvn -B package --file pom.xml + - name: Extract Maven project version + run: echo ::set-output name=version::$(mvn -q -Dexec.executable=echo -Dexec.args='${project.version}' --non-recursive exec:exec) + id: project + - name: 'Upload Artifact' + uses: actions/upload-artifact@v2 + with: + name: Bytecode-Viewer-${{ steps.project.outputs.version }}-SNAPSHOT + path: target/Bytecode-Viewer-${{ steps.project.outputs.version }}.jar + retention-days: 90