-=[ Mr. Bumblebee ]=-
_Indonesia_

Path : /usr/lib/python2.7/dist-packages/hgext/convert/
File Upload :
Current File : //usr/lib/python2.7/dist-packages/hgext/convert/monotone.pyc

ó
làÁ\c@s‡ddlZddlZddlmZddlmZmZmZmZddlm	Z	ddl
mZdee	fd„ƒYZdS(iÿÿÿÿN(tutil(tNoRepotcommittconverter_sourcet	checktool(tcommandline(t_tmonotone_sourcecBs°eZddd„Zd„Zd„Zd„Zd„Zd„Zd„Z	d„Z
d„Zd	„Zd
„Z
d„Zd„Zd
„Zd„Zd„Zd„Zd„ZRS(c
Cs‚tj||||ƒtj||dƒ||_||_t|_||_tt	dƒ|ƒ}t
jjt
jj|dƒƒsây,t
|dƒ}|jdƒ}|jƒWntk
rÉd}nX|dkrâ|‚qând}d	}|}	d
}
d}tj|d|ƒ|_tj|d
|d|
ƒ|_tj|d|d|
ƒ|_tj|d|d|
d|
ƒ|_tj|d|d|ƒ|_tj|d|ƒ|_tj|d|d|
ƒ|_tj||d|d|	ƒ|_|d
||d|}tj|d|dƒ|_d|_d|_d|_d|_ t!ddtddƒdS(Ntmtns+%s does not look like a monotone repositoryt_MTNtrbitsSQLite format 3s\s*s\s+"((?:\\"|[^"])*)"\s*s\s+\[(\w+)\]\s*s	(?:.|\n)+tdirtfiletcontenttadd_filetpatchtfromttotrenametdeletettagtrevisiontnametvaluetattrs
"mtn:execute"s"true"taborttdebnametmonotone("Rt__init__RtuitpathtFalset
automatestdiotrevRRtostexiststjoinR
treadtclosetIOErrortretcompiletdir_retfile_retadd_file_retpatch_ret	rename_ret	delete_rettag_retcert_retattr_execute_retNonetmanifest_revtmanifesttfilestdirsR(
tselfRRR"tnorepotftheadertspaceRRRtlinesR((s:/usr/lib/python2.7/dist-packages/hgext/convert/monotone.pyRsV				
!

$"
 				cOs-|jr|j||ŽS|j||ŽSdS(N(R!tmtnrunstdiotmtnrunsingle(R9targstkwargs((s:/usr/lib/python2.7/dist-packages/hgext/convert/monotone.pytmtnrunGs	cOs |j|d<|jd||ŽS(Ntdtautomate(Rtrun0(R9RARB((s:/usr/lib/python2.7/dist-packages/hgext/convert/monotone.pyR@Ms
cOsg}x]|jƒD]O\}}|jdt|ƒ|fƒ|r|jdt|ƒ|fƒqqW|rŒ|jddƒ|jdƒn|jdƒx(|D] }|dt|ƒ|f7}q W|jdƒdj|ƒ}|jjd|ƒ|jj|ƒ|jj	ƒ|j
|ƒS(Ns%s:%sitotetlRsmtn: sending '%s'
(t	iteritemstappendtlentinsertR%Rtdebugt
mtnwritefptwritetflushtmtnstdioreadcommandoutput(R9RARBtcommandtktvtarg((s:/usr/lib/python2.7/dist-packages/hgext/convert/monotone.pyR?Qs"$



cCsÉd}d}xJ|dkrX|jjdƒ}|sKtjtdƒƒ‚n||7}qW|d }|jjdƒ}|dkrtjtdƒ|ƒ‚n|jjdƒ}|dkrÓtjtdƒƒ‚nd}d}xJ|dkr+|jjdƒ}|stjtd	ƒƒ‚n||7}qâWyt|d ƒ}Wn*tk
rltjtd
ƒ|ƒ‚nX|jj|ƒ}t|ƒ|kr¹tjtdƒt|ƒ|fƒ‚n||||fS(NRt:is%bad mtn packet - no end of commandnbriÿÿÿÿtmewptls#bad mtn packet - bad stream type %ss'bad mtn packet - no divider before sizes&bad mtn packet - no end of packet sizes#bad mtn packet - bad packet size %ss9bad mtn packet - unable to read full packet read %s of %s(	R4t	mtnreadfpR&RtAbortRtlongt	TypeErrorRL(R9R&t
commandnbrtstreamt	lengthstrtlength((s:/usr/lib/python2.7/dist-packages/hgext/convert/monotone.pytmtnstdioreadpackeths>

cCsg}xøtr|jƒ\}}}}|jjd|||fƒ|dkr‚|dkr~tjtdƒ||fƒ‚nPq	|dkr¾|jjtdƒ|jƒ|jj|ƒq	|dkrá|jjd|ƒq	|d	kr	|j	|ƒq	q	Wd
j
|ƒS(Nsmtn: read packet %s:%s:%s
RIt0smtn command '%s' returned %stews
%s error:
tpsmtn: tmR(tTrueRaRRNRRZRtwarnRSRKR%(R9RStretvalR]R^R`toutput((s:/usr/lib/python2.7/dist-packages/hgext/convert/monotone.pyRRŽs$	cCs|j|krdS|jd|ƒjdƒ|_||_i|_i|_x³|jD]¨}|jj|ƒ}|rÍd}|jdƒ}|jdƒ}|j	j|ƒr·|d7}n||f|j|<n|j
j|ƒ}|rVt|j|jdƒ<qVqVWdS(Ntget_manifest_ofs

Riitx(R5RCtsplitR6R7R8R,tmatchtgroupR3R+Rf(R9R"RHReRRtnode((s:/usr/lib/python2.7/dist-packages/hgext/convert/monotone.pytmtnloadmanifest¨s$			
cCs|j|ƒ||jkS(N(RpR7(R9RR"((s:/usr/lib/python2.7/dist-packages/hgext/convert/monotone.pyt	mtnisfile½s
cCs|j|ƒ||jkS(N(RpR8(R9RR"((s:/usr/lib/python2.7/dist-packages/hgext/convert/monotone.pytmtnisdirÂs
cCsÕidd6dd6dd6dd6}|jd|ƒ}tjd|ƒ}xi|D]a}|jj|ƒ}|rM|jƒ\}}|jdd	ƒ}|jd
dƒ}|||<qMqMW|djdƒd
d|d<|S(Ns	<missing>tauthortdatet	changelogtbranchtcertss

      key ["\[]s\"t"s\\s\t.is UTC(RCR)RlR2Rmtgroupstreplace(R9R"RwtcertlistRHReRR((s:/usr/lib/python2.7/dist-packages/hgext/convert/monotone.pytmtngetcertsÆs
cCs*|js|jdƒjƒS|jgSdS(Ntleaves(R"RCt
splitlines(R9((s:/usr/lib/python2.7/dist-packages/hgext/convert/monotone.pytgetheadsÝs	cCs|jd|ƒjdƒ}i}i}g}i}xI|D]A}|jj|ƒ}|r|||jdƒ<|||jdƒ<n|jj|ƒ}|r¯|||jdƒ<n|jj|ƒ}|rÝ|||jdƒ<n|jj|ƒ}|r:|jdƒ}	|jdƒ}
|j|	|ƒrPd||	<|
||	<|||	<|||
<q{|j	|	|ƒr{|j
|
|	fƒq{q:q:Wxí|D]å\}}i}
x[|jD]P}||krºq¢n|j|dƒr¢||t
|ƒ|
|<d||<q¢q¢WxQ|
jƒD]C\}}|jjtdƒ||fdƒ|||<|||<qWx|
jƒD]}|||<qWWq†W|jƒ|fS(Ntget_revisions

iit/s3copying file in renamed directory from '%s' to '%s's
(RCRlR-RmRnR.R0R/RqRrRKR7t
startswithRLtitemsRRNRtvalues(R9R"RR7t
ignoremovetrenameddirstcopiesRHRettonametfromnametfromdirttodirtrenamedttofiletfromfile((s:/usr/lib/python2.7/dist-packages/hgext/convert/monotone.pyt
getchangesãsV





cCsƒ|j||ƒst‚ny|jd|d|ƒ}Wntk
rPt‚nX|j|ƒ|jj|dƒ\}}||fS(Ntget_file_oftrR(NR(RqR(RCt	ExceptionRpR7tgetR4(R9RR"tdataRoR((s:/usr/lib/python2.7/dist-packages/hgext/convert/monotone.pytgetfiles	


cCs£i}|j|ƒ}|jdƒ|dkr;d|d<ntd|ddtjtj|ddƒƒd|d	d
|d|jd|ƒjƒd|dd|ƒS(
NtsuspendRvt1R'RsRts%Y-%m-%dT%H:%M:%StdescRuR"tparentstextra(R}R”RRtdatestrtstrdateRCR(R9R"R›Rw((s:/usr/lib/python2.7/dist-packages/hgext/convert/monotone.pyt	getcommit&s



cCsdi}xW|jdƒjdƒD]=}|jj|ƒ}|r|jdƒ||jdƒ<qqW|S(Nttagss

ii(RCRlR1RmRn(R9RŸRHRe((s:/usr/lib/python2.7/dist-packages/hgext/convert/monotone.pytgettags4s#cCs
t‚dS(N(tNotImplementedError(R9R"ti((s:/usr/lib/python2.7/dist-packages/hgext/convert/monotone.pytgetchangedfiles<scCs0d}y|jdƒ}t|ƒ}Wn&tk
rMtjtdƒƒ‚nX|dkrt|_|jj	d|ƒ|j
ddd|jƒ\|_|_
|j
jƒ}|d	krÕtjtd
ƒ|ƒ‚nxT|dkr|j
jƒ}|sØtjtdƒƒ‚qØqØWn|jj	d
|ƒdS(Ngtinterface_versions2unable to determine mtn automate interface versiong(@s/mtn automate version %s - using automate stdio
REtstdios-dsformat-version: 2
s(mtn automate stdio header unexpected: %ss
s1failed to reach end of mtn automate stdio headerss^mtn automate version %s - not using automate stdio (automate >= 12.0 - mtn >= 0.46 is needed)
(R@tfloatR“RRZRRfR!RRNt_run2RRORYtreadline(R9tversiont
versionstrR&((s:/usr/lib/python2.7/dist-packages/hgext/convert/monotone.pytbeforeAs,
	
cCs<|jr8|jjƒd|_|jjƒd|_ndS(N(R!ROR'R4RY(R9((s:/usr/lib/python2.7/dist-packages/hgext/convert/monotone.pytafteras
	
	
N(t__name__t
__module__R4RRCR@R?RaRRRpRqRrR}R€RR–RžR R£R«R¬(((s:/usr/lib/python2.7/dist-packages/hgext/convert/monotone.pyRs$7				&							8					 (
R#R)t	mercurialRtcommonRRRRRtmercurial.i18nRR(((s:/usr/lib/python2.7/dist-packages/hgext/convert/monotone.pyt<module>	s
"

Copyright © 2017 || Recoded By Mr.Bumblebee