Skip to content

Commit

Permalink
Now any error in the action is propagated
Browse files Browse the repository at this point in the history
  • Loading branch information
andreacomo committed Sep 26, 2022
1 parent d79c662 commit 2e24eec
Showing 1 changed file with 13 additions and 4 deletions.
17 changes: 13 additions & 4 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,18 @@ runs:
steps:
- id: evaluate
name: Extract GAV
env:
EVALUATE: org.apache.maven.plugins:maven-help-plugin:3.2.0:evaluate
run: |
echo "::set-output name=group-id::$(mvn -f ${{ inputs.pom-location }} org.apache.maven.plugins:maven-help-plugin:3.2.0:evaluate -Dexpression=project.groupId -q -DforceStdout)"
echo "::set-output name=artifact-id::$(mvn -f ${{ inputs.pom-location }} org.apache.maven.plugins:maven-help-plugin:3.2.0:evaluate -Dexpression=project.artifactId -q -DforceStdout)"
echo "::set-output name=version::$(mvn -f ${{ inputs.pom-location }} org.apache.maven.plugins:maven-help-plugin:3.2.0:evaluate -Dexpression=project.version -q -DforceStdout)"
echo "::set-output name=name::$(mvn -f ${{ inputs.pom-location }} org.apache.maven.plugins:maven-help-plugin:3.2.0:evaluate -Dexpression=project.name -q -DforceStdout)"
VALUE=$(mvn -f ${{ inputs.pom-location }} $EVALUATE -Dexpression=project.groupId -q -DforceStdout)
echo "::set-output name=group-id::$VALUE"
VALUE=$(mvn -f ${{ inputs.pom-location }} $EVALUATE -Dexpression=project.artifactId -q -DforceStdout)
echo "::set-output name=artifact-id::$VALUE"
VALUE=$(mvn -f ${{ inputs.pom-location }} $EVALUATE -Dexpression=project.version -q -DforceStdout)
echo "::set-output name=version::$VALUE"
VALUE=$(mvn -f ${{ inputs.pom-location }} $EVALUATE -Dexpression=project.name -q -DforceStdout)
echo "::set-output name=name::$VALUE"
shell: bash

0 comments on commit 2e24eec

Please sign in to comment.