Mercurial > repos > bcclaywell > argo_navis
comparison venv/lib/python2.7/site-packages/pip/models/index.py @ 0:d67268158946 draft
planemo upload commit a3f181f5f126803c654b3a66dd4e83a48f7e203b
author | bcclaywell |
---|---|
date | Mon, 12 Oct 2015 17:43:33 -0400 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
-1:000000000000 | 0:d67268158946 |
---|---|
1 from pip._vendor.six.moves.urllib import parse as urllib_parse | |
2 | |
3 | |
4 class Index(object): | |
5 def __init__(self, url): | |
6 self.url = url | |
7 self.netloc = urllib_parse.urlsplit(url).netloc | |
8 self.simple_url = self.url_to_path('simple') | |
9 self.pypi_url = self.url_to_path('pypi') | |
10 self.pip_json_url = self.url_to_path('pypi/pip/json') | |
11 | |
12 def url_to_path(self, path): | |
13 return urllib_parse.urljoin(self.url, path) | |
14 | |
15 | |
16 PyPI = Index('https://pypi.python.org/') |