We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent dc75cb1 commit 59b6b1aCopy full SHA for 59b6b1a
.github/workflows/shared-check-pr-labels-with-prefix.yml
@@ -28,16 +28,16 @@ jobs:
28
steps:
29
- name: Filter labels by prefix
30
id: filter
31
+ env:
32
+ LABELS_JSON: ${{ inputs.labels }}
33
run: |
34
PREFIX="${{ inputs.prefix }}"
35
- INPUT_LABEL='${{ inputs.labels }}'
- echo ======1
36
- echo $INPUT_LABEL
37
- echo ======2
+ echo "Prefix: $PREFIX"
+ echo "Input labels: $LABELS_JSON"
38
39
# Use jq to filter labels by prefix (empty prefix returns all labels)
40
- JSON_RESULT=$(echo '${{ inputs.labels }}' | \
+ JSON_RESULT=$(echo '$LABELS_JSON' | \
41
jq --arg prefix "$PREFIX" \
42
'map(select(.name | startswith($prefix))) |
43
map({(.name): .}) |
0 commit comments