/usr/lib/python2.6/site-packages/pip-8.1.1-py2.6.egg/pip/vcs
Edit: /usr/lib/python2.6/site-packages/pip-8.1.1-py2.6.egg/pip/vcs/git.pyc (10915B)
Ρς
₯Wc
@@ sθ d d k l Z d d k Z d d k Z d d k Z d d k l Z d d k l Z d d k
l Z d d k
l
Z d d k l Z l Z d d k l Z l Z e i Z e i Z e i e Z d e f d
YZ e i e d S( i ( t absolute_importN( t samefile( t
BadCommand( t parse( t request( t display_patht rmtree( t vcst VersionControlt Gitc B@ sζ e Z d Z d Z d Z d Z d d Z d Z d
Z d Z
d Z d
Z d Z
d Z d Z d Z d Z d Z d Z d Z d Z d Z d Z d Z d Z d Z e d Z RS( t gits .gitt clones git+https git+httpss git+sshs git+gits git+filec
O@ sρ | oΚ t | \ } } } } } | i d o | t | i d } | t i | i d d i d }
t | | |
| | f } | i d d } | | t | | | |
| | f } qΡ n t t
| i | | | d S( Nt filet /s \t +i ( t urlsplitt endswitht lent lstript urllib_requestt url2pathnamet replacet
urlunsplitt findt superR t __init__( t selft urlt argst kwargst schemet netloct patht queryt fragmentt initial_slashest newpatht
after_plus( ( sC /usr/lib/python2.6/site-packages/pip-8.1.1-py2.6.egg/pip/vcs/git.pyR s
%c C@ s{ t i d d } | i | zJ | i d p | d } n | i d d d d | g d t d | Wd
t | Xd
S( s@ Export the Git repository at the url to the destination locations -exports pip-R
s checkout-indexs -as -fs --prefixt show_stdoutt cwdN( t tempfilet mkdtempt unpackR t run_commandt FalseR ( R t locationt temp_dir( ( sC /usr/lib/python2.6/site-packages/pip-8.1.1-py2.6.egg/pip/vcs/git.pyt export4 s
c C@ sc | i | } d | } | | j o | | g S| | j o | | g St i d | | Sd S( sΆ Check the revision options before checkout to compensate that tags
and branches may need origin/ as a prefix.
Returns the SHA1 of the branch or tag if found.
s origin/%ss5 Could not find a tag or branch '%s', assuming commit.N( t get_short_refst loggert warning( R t revt destt rev_optionst revisionst
origin_rev( ( sC /usr/lib/python2.6/site-packages/pip-8.1.1-py2.6.egg/pip/vcs/git.pyt check_rev_optionsA s
c C@ s | i | i | d S( s
Compare the current sha to the ref. ref may be a branch or tag name,
but current rev will always point to a sha. This means that a branch
or tag will never compare as True. So this ultimately only matches
against exact shas.
i ( t get_revisiont
startswith( R R4 R5 ( ( sC /usr/lib/python2.6/site-packages/pip-8.1.1-py2.6.egg/pip/vcs/git.pyt
check_versionU s c C@ sJ | i d d | g d | | i d d g | d | | i | d S( Nt configs remote.origin.urlR' t checkouts -q( R+ t update_submodules( R R4 R R5 ( ( sC /usr/lib/python2.6/site-packages/pip-8.1.1-py2.6.egg/pip/vcs/git.pyt switch^ s c C@ sn | i d d g d | | o | i | d | | } n | i d d d g | d | | i | d S( Nt fetchs -qR' i t resets --hard( R+ R8 R> ( R R4 R5 ( ( sC /usr/lib/python2.6/site-packages/pip-8.1.1-py2.6.egg/pip/vcs/git.pyt updated s c C@ sφ | i \ } } | o | g } d | } n d g } d } | i | | | | o t i d | | t | | i d d | | g | oM | i | | | } | i | | p! | i d d g | d | qα n | i | n d S( Ns (to %s)s
origin/mastert s Cloning %s%s to %sR s -qR= R' ( t get_url_revt check_destinationR1 t infoR R+ R8 R; R> ( R R4 R R3 R5 t rev_display( ( sC /usr/lib/python2.6/site-packages/pip-8.1.1-py2.6.egg/pip/vcs/git.pyt obtainp s" c C@ sQ | i d d d g d t d | } | i d } | i d d } | i S( s+ Return URL of the first remote encountered.R<