Skip to content

Commit

Permalink
intermediate steps
Browse files Browse the repository at this point in the history
  • Loading branch information
dili91 committed Dec 21, 2023
1 parent 02c950e commit 5bced71
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions .github/workflows/release-snapshot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,12 +37,14 @@ jobs:
- name: Create Snapshot version
run: |
CHECKOUT_REF=${{inputs.checkout_ref}}
STRIPPED_CHECKOUT_REF=${CHECKOUT_REF##*/}
echo "checkout_ref=$CHECKOUT_REF"
echo "project_version_snapshot=${{inputs.project_version}}-${CHECKOUT_REF##*/}-SNAPSHOT" >> $GITHUB_ENV
echo "stripped_checkout_ref=$STRIPPED_CHECKOUT_REF" >> $GITHUB_ENV
echo "project_version_snapshot=${{inputs.project_version}}-$STRIPPED_CHECKOUT_REF-SNAPSHOT" >> $GITHUB_ENV
echo "Snapshot project version created: ${{env.project_version_snapshot}}"
- name: Snapshot version check
run: |
SNAPSHOT_VERSION_REGEX="^([0-9]+)\.([0-9]+)\.([0-9]+)-${CHECKOUT_REF##*/}-SNAPSHOT$";
SNAPSHOT_VERSION_REGEX="^([0-9]+)\.([0-9]+)\.([0-9]+)-${{env.stripped_checkout_ref}}-SNAPSHOT$";
if [[ "${{env.project_version_snapshot}}" =~ $SNAPSHOT_VERSION_REGEX ]]; then
echo "Project version ${{env.project_version_snapshot}} is valid"
else
Expand Down

0 comments on commit 5bced71

Please sign in to comment.