I created a pull request using
github_repo.create_pull(base='master', head=branch_name, title='title')
I can't seem to find how to close one.
Ref the PyGitHub code:
https://github.com/PyGithub/PyGithub/blob/master/github/PullRequest.py
See GitHub API, resource "Pulls", Update a pull request for query parameter state
state
stringEither
open
,closed
, orall
to filter by state.Default:
open
I'd say you want to update the PR with query-parameter asstate=closed
:
pr = ??? Code to get the PR you want ???
pr.edit(state="closed")