File tree Expand file tree Collapse file tree 1 file changed +10
-13
lines changed Expand file tree Collapse file tree 1 file changed +10
-13
lines changed Original file line number Diff line number Diff line change @@ -23,20 +23,17 @@ jobs:
2323 run : |
2424 PREVIOUS_TAG=$(git describe --tags --abbrev=0)
2525 TAG_DATE=$(git log -1 --format="%ci" "$PREVIOUS_TAG" | sed 's/ /T/' | sed 's/ +0000/Z/')
26- echo "$TAG_DATE"
26+ echo "Using tag date: $TAG_DATE"
2727
28- PR_DATA=$(gh pr list \
29- --search "is:pr is:open created:>=$TAG_DATE" \
30- --json number,body \
31- --jq '.[] | select(.body != null and (.body | test("issues/\\d+"))) | [.body | scan("issues/(\\d+)"; "g")] | .[]'
32- )
33- echo "Found PRs:"
34- echo "$PR_DATA"
35- gh pr list \
36- --search "is:pr is:open created:>=$TAG_DATE" \
37- --json number,body \
38- --jq '.[] | select(.body != null and (.body | test("issues/\\d+"))) | [.body | scan("issues/(\\d+)"; "g")] | .[]'
39- | while read issue_number; do
28+ ISSUE_NUMBERS=$(gh pr list --search "is:pr is:open created:>=$TAG_DATE" --json number,body --jq '.[] | select(.body != null and (.body | test("issues/\\d+"))) | [.body | scan("issues/(\\d+)"; "g")] | .[]' | sort -u)
29+
30+ if [ -z "$ISSUE_NUMBERS" ]; then
31+ echo "No issues found in recent PRs"
32+ exit 0
33+ fi
34+
35+ echo "Found issues: $ISSUE_NUMBERS"
36+ for issue_number in $ISSUE_NUMBERS; do
4037 echo "Commenting on issue #$issue_number"
4138 gh issue comment "$issue_number" --body "This issue was resolved and included in the latest release."
4239 done
You can’t perform that action at this time.
0 commit comments