diff --git a/README.rst b/README.rst index 339e10c..49ddb30 100644 --- a/README.rst +++ b/README.rst @@ -112,6 +112,9 @@ Check `GitHub `_ for updates. The version returned is in da github The github repository, with author, e.g. ``lilydjwg/nvchecker``. +branch + Which branch to track? Default: ``master``. + Check PyPI ---------- Check `PyPI `_ for updates. diff --git a/nvchecker/source/github.py b/nvchecker/source/github.py index 814afb4..7e2bdda 100644 --- a/nvchecker/source/github.py +++ b/nvchecker/source/github.py @@ -3,11 +3,12 @@ from functools import partial from tornado.httpclient import AsyncHTTPClient -GITHUB_URL = 'https://api.github.com/repos/%s/commits' +GITHUB_URL = 'https://api.github.com/repos/%s/commits?sha=%s' def get_version(name, conf, callback): repo = conf.get('github') - url = GITHUB_URL % repo + br = conf.get('branch', 'master') + url = GITHUB_URL % (repo, br) AsyncHTTPClient().fetch(url, user_agent='lilydjwg/nvchecker', callback=partial(_github_done, name, callback)) diff --git a/sources/arch_aur.ini b/sources/arch_aur.ini index 20f0ce5..d351461 100644 --- a/sources/arch_aur.ini +++ b/sources/arch_aur.ini @@ -59,6 +59,7 @@ regex = svgwrite-([\d.]+).zip [you-get-git] github = soimort/you-get +branch = develop [ssed] url = http://sed.sourceforge.net/grabbag/ssed/