ci: add missing parameters and push when issue closed

This commit is contained in:
Guoguo
2026-01-14 03:12:09 +00:00
parent 2bd277b57d
commit c98000069a

View File

@@ -2,7 +2,7 @@ name: Issue Tracker
on: on:
issues: issues:
types: [opened, reopened] types: [opened, reopened, closed]
jobs: jobs:
track-issue: track-issue:
@@ -28,8 +28,10 @@ jobs:
--arg state "${{ github.event.issue.state }}" \ --arg state "${{ github.event.issue.state }}" \
--arg created_at "${{ github.event.issue.created_at }}" \ --arg created_at "${{ github.event.issue.created_at }}" \
--arg updated_at "${{ github.event.issue.updated_at }}" \ --arg updated_at "${{ github.event.issue.updated_at }}" \
--arg closed_at "${{ github.event.issue.closed_at }}" \
--arg url "${{ github.event.issue.html_url }}" \ --arg url "${{ github.event.issue.html_url }}" \
--arg user_login "${{ github.event.issue.user.login }}" \ --arg user_login "${{ github.event.issue.user.login }}" \
--arg repository "${{ github.repository }}" \
--argjson labels "$RAW_LABELS" \ --argjson labels "$RAW_LABELS" \
--argjson assignees "$RAW_ASSIGNEES" \ --argjson assignees "$RAW_ASSIGNEES" \
'{ '{
@@ -42,11 +44,13 @@ jobs:
state: $state, state: $state,
created_at: $created_at, created_at: $created_at,
updated_at: $updated_at, updated_at: $updated_at,
closed_at: $closed_at,
url: $url, url: $url,
user: { login: $user_login }, user: { login: $user_login },
labels: $labels, labels: $labels,
assignees: $assignees assignees: $assignees
} },
repository: { name: $repository },
}') }')
RESPONSE=$(curl -s -w "\n%{http_code}" -X POST "$API_URL" \ RESPONSE=$(curl -s -w "\n%{http_code}" -X POST "$API_URL" \