Skip to content

Commit 6903e4e

Browse files
committed
add dry run support to test
1 parent 3f6e749 commit 6903e4e

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed

.github/workflows/test.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,5 @@ jobs:
88
- name: Validate Plugin Version
99
uses: ./
1010
with:
11-
plugin-path: '.github/workflows/fixtures/plugin-test/'
11+
plugin-path: '.github/workflows/fixtures/plugin-test/'
12+
dry-run: true

bin/validate-plugin-version.sh

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,12 @@ main(){
6262
exit 1
6363
fi
6464

65+
# Bail before committing anything if we're dry-running.
66+
if [[ "${DRY_RUN}" == "true" ]]; then
67+
echo "Dry run enabled. Happy testing."
68+
exit 0
69+
fi
70+
6571
git config user.name "github-actions"
6672
git config user.email "[email protected]"
6773
git checkout -b "$BRANCH_NAME"

0 commit comments

Comments
 (0)