Now any error in the action is propagated

This commit is contained in:
Andrea Como 2022-09-26 23:24:54 +02:00
parent d79c662fd0
commit 2e24eecb9a

View File

@ -26,9 +26,18 @@ runs:
steps: steps:
- id: evaluate - id: evaluate
name: Extract GAV name: Extract GAV
env:
EVALUATE: org.apache.maven.plugins:maven-help-plugin:3.2.0:evaluate
run: | 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)" VALUE=$(mvn -f ${{ inputs.pom-location }} $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=group-id::$VALUE"
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.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 shell: bash