Skip to content

Commit 0dd36d5

Browse files
committed
add URL scheme validation
Signed-off-by: tdruez <tdruez@aboutcode.org>
1 parent b04bda5 commit 0dd36d5

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

action.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,11 @@ runs:
141141
run: |
142142
INPUT_URL_CLI_ARGS=""
143143
for url in $INPUT_URLS; do
144-
INPUT_URL_CLI_ARGS+=" --input-url $url"
144+
if [[ "$url" =~ ^(https?|docker|pkg): ]]; then
145+
INPUT_URL_CLI_ARGS+=" --input-url $url"
146+
else
147+
echo "::warning::Skipping unsupported URL scheme: $url"
148+
fi
145149
done
146150
echo "INPUT_URL_CLI_ARGS=${INPUT_URL_CLI_ARGS}" >> $GITHUB_ENV
147151

0 commit comments

Comments
 (0)