Agent skill · openhands
github-issue-to-pr
Create an automation that implements GitHub issues when a configurable trigger label is applied. Polls one or more repositories deterministically, clones the default branch, starts one OpenHands conversation per label event, then commits, pushes, and opens the pull request itself.
What it needs
About 10k tokens when loaded.
What this skill does
GitHub Issue to PR Automation Create a cron automation that watches one or more GitHub repositories for issues with a trigger label, starts an OpenHands conversation once per label event with the repository's default branch already checked out, and opens a pull request with whatever the agent produced. The automation script is deterministic: issue discovery, label-event tracking, state persistence, the clone, the branch, the commit, the push, the pull request, the issue comments, and the clone's removal are all handled in Python. The LLM is invoked only to write the code. The agent is told which issue to implement, not what it says. It fetches the description, the discussion, and whatever they link to itself, so nothing in the prompt goes stale between dispatch and the moment the agent reads it. That needs read access, so the conversation is handed exactly one secret, GITHUBPERSONALACCESSTOKEN, and no MCP servers. AGENTSECRETNAMES stays an allow-list: the rest of the deployment's secret store is not reachable from a conversation whose instructions came from an issue. The agent also finishes the job: it commits, pushes its branch, and opens the pull request, so the pull request appears when the agent stops rather than on the next poll. The script does not trust that it happened - when the conversation ends it asks GitHub whether the pull request exists, and opens it itself when it does not. origin still carries no credential, so every GitHub command the agent runs has to name GITHUBPERSONALACCESSTOKEN; the SDK only puts a secret in the environment of a command that mentions it, and masks it in the output. …
How to use it
Reference it in AdaL, Claude Code, Cursor or any coding agent — nothing to install:
@skills openhands/github-issue-to-pr