2012-11-20 19:43:35 +01:00
2012-09-16 20:39:00 +02:00
2012-10-28 18:51:06 +01:00
2012-11-20 19:43:35 +01:00
2012-11-20 19:43:35 +01:00
2012-11-20 19:36:28 +01:00

This is a Python library to access the Github API v3.

With it, you can manage your Github resources (repositories, user profiles, organizations, etc.) from Python scripts.

It covers the full API, and all methods are tested against the real Github site.

Should you have any question, or if you find a bug, or if there is something you can do with the API but not with PyGithub, please open an issue.

PyGithub is stable. I will maintain it up to date with the API, and fix bugs if any, but I don't plan new heavy developments.

What's new?

Build Status

Version 1.9.1 (November 20th, 2012)

  • Fix an assertion failure when integers returned by Github do not fit in a Python int

Version 1.9.0 (November 19th, 2012)

  • You can now use your client_id and client_secret to increase rate limiting without authentication
  • You can now send a custom User-Agent
  • PullRequest now has its 'assignee' attribute, thank you mstead
  • Repository.edit now has 'default_branch' parameter
  • create_repo has 'auto_init' and 'gitignore_template' parameters
  • GistComment URL is changed (see http://developer.github.com/changes/2012-10-31-gist-comment-uris)
  • A typo in the readme was fixed by tymofij, thank you
  • Internal stuff:
    • Add encoding comment to Python files, thank you Zearin
    • Restore support of Python 2.5
    • Restore coverage measurement in setup.py test
    • Small refactoring

Previous versions

See ChangeLog.

Download and install

This package is in the Python Package Index, so easy_install PyGithub or pip install PyGithub should be enough. You can also clone it on Github.

Tutorial

First create a Github instance:

from github import Github

g = Github( "user", "password" )

Then play with your Github objects:

for repo in g.get_user().get_repos():
    print repo.name
    repo.edit( has_wiki = False )

You can also create a Github instance with an OAuth token:

g = Github( token )

Or without authentication:

g = Github()

Reference documentation

You need to use a Github API and wonder which class implements it? Reference of APIs

You want all the details about PyGithub classes? Reference of classes

Licensing

PyGithub is distributed under the GNU Lesser General Public Licence. See files COPYING and COPYING.LESSER, as requested by GNU.

Projects using PyGithub

(Open an issue if you want to be listed here, I'll be glad to add your project)

They talk about PyGithub

S
Description
Typed interactions with the GitHub API v3
https://pygithub.readthedocs.io/
Readme
12 MiB
Languages
Python 99.9%