Skip to content

Commit 3614a36

Browse files
Update .github/workflows/release.yml
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
1 parent b0f11b5 commit 3614a36

1 file changed

Lines changed: 14 additions & 3 deletions

File tree

.github/workflows/release.yml

Lines changed: 14 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -209,10 +209,21 @@ jobs:
209209
210210
- name: Collect release assets
211211
run: |
212+
set -e
213+
VERSION="${{ steps.validate_tag.outputs.version }}"
212214
mkdir -p artifacts
213-
cp xapi-client/target/xapi-client-${{version}}.jar artifacts/
214-
cp xapi-model/target/xapi-model-${{version}}.jar artifacts/
215-
cp xapi-model-spring-boot-starter/target/xapi-model-spring-boot-starter-${{version}}.jar artifacts/
215+
# Define artifact paths
216+
CLIENT_JAR="target/checkout/xapi-client/target/xapi-client-${VERSION}.jar"
217+
MODEL_JAR="target/checkout/xapi-model/target/xapi-model-${VERSION}.jar"
218+
STARTER_JAR="target/checkout/xapi-model-spring-boot-starter/target/xapi-model-spring-boot-starter-${VERSION}.jar"
219+
# Check existence and copy
220+
for JAR in "$CLIENT_JAR" "$MODEL_JAR" "$STARTER_JAR"; do
221+
if [ ! -f "$JAR" ]; then
222+
echo "::error::Artifact not found: $JAR"
223+
exit 1
224+
fi
225+
cp "$JAR" artifacts/
226+
done
216227
217228
- name: Upload release assets
218229
env:

0 commit comments

Comments
 (0)