-
Notifications
You must be signed in to change notification settings - Fork 49
Open
Description
Why
The amber-issue-handler workflow is ~656 lines. Five actions/github-script@v8 blocks contain inline JavaScript (including ~170 lines of retry/backoff infrastructure) that can be replaced with gh CLI commands — cutting the file roughly in half, making it easier to maintain, and eliminating the Octokit JS dependency.
gh CLI is natively available in GitHub Actions runners and well-supported by Claude Code for future modifications.
Changes (in order)
- Extract issue details — Replace
actions/github-scriptwithgh issue view+jq(~30 lines saved) - Check for existing PR — Simplify complex
jqregex togh pr list --search(~10 lines saved) - Report no changes — Replace
actions/github-scriptwithgh issue comment(~20 lines saved) - Validate changes — Replace
actions/github-script+execFilewithgit diff --stat+gh issue comment(~25 lines saved) - Create or Update PR — Replace
actions/github-script(includingretryWithBackoff/safeCommentinfrastructure) withgh pr create+gh pr edit --add-label+gh issue comment(~110 lines saved) - Report failure — Replace
actions/github-scriptwithgh issue comment(~25 lines saved)
Estimated total: ~220 lines saved, 0 actions/github-script blocks remaining.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels