remove Google Code sources
This commit is contained in:
parent
a82c18c376
commit
ad583dd59a
16
README.rst
16
README.rst
|
@ -35,8 +35,6 @@ Contents
|
|||
* `Check Arch Linux official packages <#check-arch-linux-official-packages>`_
|
||||
* `Check Debian Linux official packages <#check-debian-linux-official-packages>`_
|
||||
* `Check Ubuntu Linux official packages <#check-ubuntu-linux-official-packages>`_
|
||||
* `Check Google Code (hg repository) <#check-google-code-hg-repository>`_
|
||||
* `Check Google Code (svn repository) <#check-google-code-svn-repository>`_
|
||||
* `Manually updating <#manually-updating>`_
|
||||
* `Version Control System (VCS) (git, hg, svn, bzr) <#version-control-system-vcs-git-hg-svn-bzr>`_
|
||||
* `Other <#other>`_
|
||||
|
@ -347,20 +345,6 @@ suite
|
|||
strip-release
|
||||
Strip the release part.
|
||||
|
||||
Check Google Code (hg repository)
|
||||
---------------------------------
|
||||
Check a mercurial (hg) repository on `Google Code <https://code.google.com/>`_ for updates. The version returned is in date format ``%Y%m%d``, e.g. ``20130701``.
|
||||
|
||||
gcode_hg
|
||||
The name used on Google Code, e.g. ``chromium-compact-language-detector``.
|
||||
|
||||
Check Google Code (svn repository)
|
||||
----------------------------------
|
||||
Check a subversion (svn) repository on `Google Code <https://code.google.com/>`_ for updates. The version returned is the svn resivion number.
|
||||
|
||||
gcode_svn
|
||||
The name used on Google Code, e.g. ``cld2``.
|
||||
|
||||
Manually updating
|
||||
-----------------
|
||||
This enables you to manually specify the version (maybe because you want to approve each release before it gets to the script).
|
||||
|
|
|
@ -6,8 +6,9 @@ from importlib import import_module
|
|||
|
||||
logger = logging.getLogger(__name__)
|
||||
handler_precedence = (
|
||||
'github', 'aur', 'pypi', 'archpkg', 'debianpkg', 'ubuntupkg', 'gems', 'pacman',
|
||||
'cmd', 'bitbucket', 'gcode_hg', 'gcode_svn', 'regex', 'manual', 'vcs',
|
||||
'github', 'aur', 'pypi', 'archpkg', 'debianpkg', 'ubuntupkg',
|
||||
'gems', 'pacman',
|
||||
'cmd', 'bitbucket', 'regex', 'manual', 'vcs',
|
||||
'cratesio', 'npm', 'hackage', 'cpan', 'gitlab', 'packagist'
|
||||
)
|
||||
|
||||
|
|
|
@ -1,27 +0,0 @@
|
|||
# MIT licensed
|
||||
# Copyright (c) 2013-2017 lilydjwg <lilydjwg@gmail.com>, et al.
|
||||
|
||||
import re
|
||||
import time
|
||||
import logging
|
||||
from . import session
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
GCODE_URL = 'https://code.google.com/p/%s/source/list'
|
||||
GCODE_HG_RE = re.compile(
|
||||
r'<a onclick="cancelBubble=true" href="detail\?r=[0-9a-f]+">([^<]+)</a>')
|
||||
|
||||
async def get_version(name, conf):
|
||||
repo = conf.get('gcode_hg') or name
|
||||
url = GCODE_URL % repo
|
||||
async with session.get(url) as res:
|
||||
data = await res.text()
|
||||
m = GCODE_HG_RE.search(data)
|
||||
if m:
|
||||
t = time.strptime(m.group(1), '%b %d, %Y')
|
||||
version = time.strftime('%Y%m%d', t)
|
||||
else:
|
||||
logger.error('%s: version not found.', name)
|
||||
version = None
|
||||
return name, version
|
|
@ -1,24 +0,0 @@
|
|||
# MIT licensed
|
||||
# Copyright (c) 2013-2017 lilydjwg <lilydjwg@gmail.com>, et al.
|
||||
|
||||
import re
|
||||
import logging
|
||||
from . import session
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
GCODE_URL = 'https://code.google.com/p/%s/source/list'
|
||||
GCODE_SVN_RE = re.compile(r'<a href="detail\?r=\d+">r(\d+)</a>')
|
||||
|
||||
async def get_version(name, conf):
|
||||
repo = conf.get('gcode_svn') or name
|
||||
url = GCODE_URL % repo
|
||||
async with session.get(url) as res:
|
||||
data = await res.text()
|
||||
m = GCODE_SVN_RE.search(data)
|
||||
if m:
|
||||
version = m.group(1)
|
||||
else:
|
||||
logger.error('%s: version not found.', name)
|
||||
version = None
|
||||
return name, version
|
|
@ -34,8 +34,5 @@ proxy = localhost:8087
|
|||
[PySide]
|
||||
pypi = PySide
|
||||
|
||||
[python-cld2-hg]
|
||||
gcode_hg = chromium-compact-language-detector
|
||||
|
||||
[test]
|
||||
manual = 0.1
|
||||
|
|
Loading…
Reference in New Issue