\x89\x50\x4E\x47\x0D\x0A\x1A\x0A PNG  \x89\x50\x4E\x47\x0D\x0A\x1A\x0A  13\c@@sddlmZddlZddlmZddlmZmZmZ ddl m Z de fdYZ d d d d d dhZde je jfdYZdS(i(tabsolute_importN(t_(tconfigterrortnodei(tcommont submodulecB@s#eZdZdZdZRS(cC@s||_||_||_dS(N(tpathRturl(tselfRRR((s7/usr/lib64/python2.7/site-packages/hgext/convert/git.pyt__init__s  cC@sd|j|jfS(Ns %s = [git]%s(RR(R ((s7/usr/lib64/python2.7/site-packages/hgext/convert/git.pythgsubscC@sd|j|jfS(Ns%s %s(RR(R ((s7/usr/lib64/python2.7/site-packages/hgext/convert/git.pyt hgsubstates(t__name__t __module__R R R (((s7/usr/lib64/python2.7/site-packages/hgext/convert/git.pyRs  ttreetparenttauthort committertbranchtcloset convert_gitcB@seZdZdZdZdZdZdZddZ dZ dZ d Z d Z d Zd Zd ZdZdZdZdZdZdZddZRS(cO@s|d|j||S(Ns --git-dir=%s(R(R tcmdtargstkwargs((s7/usr/lib64/python2.7/site-packages/hgext/convert/git.pyt_gitcmd3scO@s|j|j||S(N(Rtrun0(R RR((s7/usr/lib64/python2.7/site-packages/hgext/convert/git.pytgitrun06scO@s|j|j||S(N(Rtrun(R RR((s7/usr/lib64/python2.7/site-packages/hgext/convert/git.pytgitrun9scO@s|j|j||S(N(Rt runlines0(R RR((s7/usr/lib64/python2.7/site-packages/hgext/convert/git.pyt gitrunlines0<scO@s|j|j||S(N(Rtrunlines(R RR((s7/usr/lib64/python2.7/site-packages/hgext/convert/git.pyt gitrunlines?scO@s|j|j||S(N(Rt_run3(R RR((s7/usr/lib64/python2.7/site-packages/hgext/convert/git.pytgitpipeBscC@sdtt|j|||d|tjj||dtjj|}tjj|drm|d7}ntjj |dstj t d|n|j dd}|dks|d krt jt d n|dkrQd |g|_|jdd }|r(|jjd n|j dd}|jjd|n g|_tjdd||_g|_|jdd|_|jjdd|_t|jt@}|rt jt dt djt|n|jjdd} d} d} x| D]} | jd r| } d}d| krc| jdd\} }n| dkr~|pxd} q| dkr|pd} qqqW| r| rt jt dnd| k}d| k}|r|rt jt dn|r$| r$t jt dn| r;| r;d} ni|d6|d6| d6| d6|_ dS(!Ntrevstgits/.gits/objectss&%s does not look like a Git repositorytconvertsgit.similarityiids$similarity must be between 0 and 100s-C%d%%sgit.findcopiesharders--find-copies-hardersgit.renamelimits-l%dscat-files--batchs git.extrakeyss%copying of extra key is forbidden: %ss, sgit.committeractionstmessagedifferentt messagealwayst=is committer:sFcommitteractions cannot define both messagedifferent and messagealwayst dropcommittert replaceauthorsCcommitteractions cannot define both dropcommitter and replaceauthorsCcommitteractions cannot define both dropcommitter and messagealways(R'R((!tsuperRR Rt commandlinetosRtabspathtisdirtexiststNoRepoRt configintRtAborttsimoptt configbooltappendt checktoolt submodulesR#t catfilepipetuit configlistt copyextrakeystsettbannedextrakeystjointsortedtNonet startswithtsplittcommitteractions(R R;trepotypeRR$t similaritytfindcopieshardert renamelimittbannedRER'R(tatktvR*R+((s7/usr/lib64/python2.7/site-packages/hgext/convert/git.pyR Esp"      "          cC@s"x|jD]}|jq WdS(N(R:R(R tf((s7/usr/lib64/python2.7/site-packages/hgext/convert/git.pytafterscC@s|jsQ|jddd\}}|j}|rtjtdqnhg}x_|jD]T}|jdd|\}}|j|d |ratjtd|qaqaW|S(Ns rev-parses --branchess --remotesscannot retrieve git headss--verifyiscannot retrieve git head "%s"(R$Rt splitlinesRR4RR7(R toutputtstatustheadstrevtrawheadtret((s7/usr/lib64/python2.7/site-packages/hgext/convert/git.pytgetheadss   cC@s|tjkrtn|jdj|d|jdj|jdjj}|d|krtj t d||fnt |d}|jdj |}t ||krtj t d||fn|jdj d|S(Nis iscannot read %r object at %sis,cannot read %r object at %s: unexpected size(tnodemodtnullhextIOErrorR:twritetflushtreadlineRDRR4Rtinttreadtlen(R RTtftypetinfotsizetdata((s7/usr/lib64/python2.7/site-packages/hgext/convert/git.pytcatfiles "cC@s|tjkrdS|dkrVdjg|jD]}|j^q2}d}nh|dkrdjg|jD]}|j^qu}d}n%|j|d}|j||f}||fS(Ns.hgsubs ts .hgsubstatetblob(NN( RXRYRBR@t submoditerR R Ret modecache(R tnameRTtmRdtmode((s7/usr/lib64/python2.7/site-packages/hgext/convert/git.pytgetfiles .  . cc@sGtj}x7t|jddD]}|j|kr"|Vq"q"WdS(NtkeycS@s|jS(N(R(tp((s7/usr/lib64/python2.7/site-packages/hgext/convert/git.pyts(RXRYRAR9R(R tnullRk((s7/usr/lib64/python2.7/site-packages/hgext/convert/git.pyRhs cC@sg|_tj}|jddjd|jdDx]|jD]O}||}d|krNd|krN|jjt|dd|dqNqNWdS(sParse the formatted .gitmodules file, example file format: [submodule "sub"] path = sub url = git://giturl s .gitmoduless cs@s|]}|jVqdS(N(tstrip(t.0tline((s7/usr/lib64/python2.7/site-packages/hgext/convert/git.pys sRRRfN(R9RtparseR@RDtsectionsR7R(R tcontenttctsects((s7/usr/lib64/python2.7/site-packages/hgext/convert/git.pytparsegitmoduless   cC@s|jdd|df\}}|rF|jjtd|dSy|j|Wn/tjk r|jjtd|dSXxQ|jD]F}|jdd||jf\}}|rqn|j |_ qWdS(Ntshows%s:%ss .gitmoduless2warning: cannot read submodules config file in %s s+warning: unable to parse .gitmodules in %s s rev-parse( RR;twarnRR{Rt ParseErrorR9RRrR(R tversiontmodulesRVRkR((s7/usr/lib64/python2.7/site-packages/hgext/convert/git.pytretrievegitmoduless "%c@s|rtjtdni_dddddgj|g}j|\}}|rtjtd|ngi}td}tgtg|j d}t |} d } j j d d fd } x,| | kr0|| } | d 7} |sR| j ds@qn| j }qn| } |dd dkr| }|| }| d 7} |} |||RBtFalseRDR`R;R6RCRR7RXRYR(R RtfullRRQRRtcopiesRtdifftreetlcounttiRRRNtcopysrctcopydesttfdest((RRR RRRs7/usr/lib64/python2.7/site-packages/hgext/convert/git.pyt getchangessb #                  cC@s|j|d}|jd}||d}|j|}|| j}g}d}}i} x<|dD]0} | jdd\} } | dkr| j} | d\}}dj| d }|dd kr|dd !}n|j|}n| d krg| j} | d\}}dj| d }|dd krU|dd !}n|j|}n| d kr|j| n| |jkro| | | }d|krtq\n|d jd\}}|j|q\Wny|jdddd|d ||d fd \}}|rtjtd|ng|D]}|jd ^q}|S( Ns diff-trees--roots-ms-rscannot read changes in %ss is --name-onlys%s^%dis--s (RBR!RR4RRDR7trstrip( R RRRRQRRRRkRN((s7/usr/lib64/python2.7/site-packages/hgext/convert/git.pytgetchangedfiless$      "c C@si}|jjdd}d|dfd g}dh}y|jd\}}x|D]}|j}|jdd \}} xZ|D]R\} } | j|  s| |krqnd | | t| f} ||| s