Skip to content

Commit 109ff74

Browse files
committed
chore(cicd): changes small
1 parent 99d5432 commit 109ff74

File tree

2 files changed

+7
-1
lines changed

2 files changed

+7
-1
lines changed

.github/workflows/dev.yml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,20 +94,25 @@ jobs:
9494
# qqqq now were dry running do we need to error handle?
9595
set +e
9696
# Due to dry-run need to catch error differently : SEMVER_OUTPUT_RAW=$(npx semantic-release --dry-run 2>&1) || STATUS=$?
97+
echo "running semantic-release"
9798
SEMVER_OUTPUT_RAW=$(npx semantic-release --dry-run 2>&1)
9899
STATUS=$?
100+
echo "status = $STATUS"
99101
set -e
100102
echo "$SEMVER_OUTPUT_RAW"
101103
102104
# 0 not exclusively due to no version bump so check output
103105
if [ "${STATUS:-0}" -ne 0 ]; then
104-
if echo "$SEMVER_OUTPUT_RAW" | grep -q "No release published"; then
106+
echo "in if status 0"
107+
if echo "$SEMVER_OUTPUT_RAW" | grep -q "There are no relevant changes"; then
108+
echo "in if no release published"
105109
# No new version, but we can find the current version
106110
echo "No new version required getting current version from git tags"
107111
DEV_SEMVER_VERSION=$(git describe --tags --abbrev=0 2>/dev/null || echo "0.0.0-version-not-found") # last git tag so if multiple bumps in other branches making package version there will be some discrepancy but the purpose is distinguishing them for dev purposes.
108112
echo "DEV_SEMVER_VERSION = $DEV_SEMVER_VERSION"
109113
exit 0 # treat as success code didnt fail there just was no version increment required
110114
else
115+
echo "in else no release published"
111116
exit $STATUS # real error → fail pipeline
112117
fi
113118
else

.github/workflows/release.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,7 @@ jobs:
5959
# Set error to not instantly fail so we can check if error is semantic-release classifying no version bump required as an error
6060
set +e
6161
OUTPUT=$(npx semantic-release 2>&1) || STATUS=$?
62+
echo "status = $STATUS"
6263
set -e
6364
echo "$OUTPUT"
6465

0 commit comments

Comments
 (0)