Skip to content

Commit

Permalink
infra: fix --kstest-pr option of /kickstart-test workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
rvykydal committed Jul 23, 2024
1 parent 3655898 commit 09c467b
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion .github/workflows/kickstart-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -83,12 +83,15 @@ jobs:
run: |
# extract first line and cut out the "/kickstart-tests" first word
ARGS=$(echo "$BODY" | sed -n '1 s/^[^ ]* *//p' | sed 's/[[:space:]]*$//')
# check --kstest-pr option
OPTS="$(getopt -q -o "" --long kstest-pr: -- $ARGS)" || true
PR=${OPTS#" --kstest-pr '"}
PR=$(echo $PR | cut -d " " -f1)
PR=${PR%"'"}
PR=${PR%"--"}
echo "workflow arguments are: $ARGS"
# remove --kstest-pr option
ARGS=$(echo "$ARGS" | sed -r -e "s#--kstest-pr([ ]+|=)$PR ##" | sed 's/[[:space:]]*$//')
echo "test selection arguments are: $ARGS"
echo "comment_args=${ARGS}" >> $GITHUB_OUTPUT
echo "kickstart-tests PR: $PR"
echo "kstest_pr=${PR}" >> $GITHUB_OUTPUT
Expand Down

0 comments on commit 09c467b

Please sign in to comment.