• File: _diffcommand.pyc
  • Full Path: /home3/farmfre2/public_html/ALFA_DATA/alfasymlink/root/proc/self/root/opt/alt/python27/lib64/python2.7/site-packages/lxml/html/_diffcommand.pyc
  • Date Modified: 07/17/2016 11:11 AM
  • File size: 2.83 KB
  • MIME-type: text/x-bytecode.python
  • Charset: 8 bit

]Nc@sddlZddlZddlZddlZddlmZdZejdddeZej	ddd	d
ddd
dddej	ddddddddddZdZej
dejejBZej
dejejBZdZdZdS(iN(thtmldiffttusagesR%prog [OPTIONS] FILE1 FILE2
%prog --annotate [OPTIONS] INFO1 FILE1 INFO2 FILE2 ...tdescriptions-os--outputtmetavartFILEtdesttoutputtdefaultt-thelpsFile to write the difference tos-as--annotationtactiont
store_truet
annotationsDo an annotationcCsI|dkrtjd}ntj|\}}|jrGt||St|dkrxdGHtjtj	dn|\}}t
|}t
|}t|d}t|\}}}	t||}
||
|	}
|j
dkr|
jds	|
d7}
ntjj|
n)t|j
d}|j|
|jdS(NiisError: you must give two filesR	s
twb(tNonetsystargvtparsert
parse_argsR
tannotatetlent
print_helptexitt	read_filet
split_bodyRRtendswithtstdouttwritetopentclose(targstoptionstfile1tfile2tinput1tinput2tbody1tpretbody2tposttresulttf((sI/opt/alt/python27/lib64/python2.7/site-packages/lxml/html/_diffcommand.pytmains.	



cCsl|dkrtjj}nJtjj|sCtd|n%t|d}|j}|j|S(NR	sInput file %s does not existtrb(	RtstdintreadtostpathtexiststOSErrorRR(tfilenametcR*((sI/opt/alt/python27/lib64/python2.7/site-packages/lxml/html/_diffcommand.pyR8s
s	<body.*?>s
</body.*?>cCs}tj|}|r8||j }||j}ntj|}|rp||j}||j }n|||fS(N(t
body_start_retsearchtendtbody_end_retstart(thtmltmatchR&R(((sI/opt/alt/python27/lib64/python2.7/site-packages/lxml/html/_diffcommand.pyRIscCsdGHtjddS(NsNot yet implementedi(RR(R R((sI/opt/alt/python27/lib64/python2.7/site-packages/lxml/html/_diffcommand.pyRTs(toptparseRtreR/tlxml.html.diffRRtOptionParserRt
add_optionRR+RtcompiletItSR5R8RR(((sI/opt/alt/python27/lib64/python2.7/site-packages/lxml/html/_diffcommand.pyt<module>s6