Sf ddlZddlZddlZddlZejedgdZGddeZd ddd Z dd Z d Z ed k(re yy)N) )remove)Errorencodedecodec eZdZy)rN)__name__ __module__ __qualname__)/opt/alt/python312/lib64/python3.12/uu.pyrr)srrFbacktickc g} |dk(rtjj}npt|tr`|t j j|}| t j|j}t|d}|j||dk(rtjj}n-t|trt|d}|j||d}|d}|jdd}|jdd}|jd |d z|fzj!d |j#d }t%|d kDrF|jt'j(|||j#d }t%|d kDrF|r|jdn|jd|D]}|j+y#t$rYlwxYw#|D]}|j+wxYw)N-rbwbi z\n z\rz begin %o %s iascii-rrs` end s end )sysstdinbuffer isinstancestrospathbasenamestatst_modeAttributeErroropenappendstdoutreplacewriterreadlenbinasciib2a_uuclose)in_fileout_filenamemoder opened_filesdatafs rrr,sL1 c>ii&&G  %|ww''0|777+33D7D)G    ( s?zz((H # &Hd+H    ) <D <D ||D'||D' D5L4*@@HHQR||B$i!m NN8??4(C D<<#D$i!m  NN; ' NN; 'A GGIO&NA GGIs7AG(G8D"G(%G( G%!G($G%%G((Hc g}|dk(rtjj}n-t|trt |d}|j | |j}|s td|jds0|jdd}t|dk(r|ddk(r t|d d ni||djd jd }t j"j%|rtd ||jt j&sYdt j&|vsDt j(rC|jt j(sdt j(|vrtd|d|t|d d }|dk(rtj*j}nEt|tr5t |d}t!j,|||}|j ||j}|rb|j/d dk7rN t1j2|} |j7| |j}|r|j/d dk7rN|s td |D]} | j9y#t$rYwxYw#t0j$rZ} |ddz dzdzdzdz} t1j2|d| } |s"tj4j7d| zYd} ~ d} ~ wwxYw#|D]} | j9wxYw)Nrrz'No valid begin line found in input filesbegin rrs rz Cannot overwrite existing file: z..zRefusing to write to z due to directory traversalrsend ?z Warning: %s zTruncated input file)rrrrrr%r&readliner startswithsplitr+int ValueErrorrstriprrr existssepaltsepr'chmodstripr,a2b_uustderrr)r.) r/r0r2quietr3hdr hdrfieldsfpsr4vnbytesr5s rrrfsL#~))"" GS !w%G$<""$CEFF>>(+ $*I9~"y|x'? ! a(   |**<8??HHww~~h'>xjIJJ##BFF+RVVH )II((3"))%13H:=XYZZ <y|Q'D s?zz((H # &h%B HHXt $H    )    AGGL)V3 :q) NN4   "AAGGL)V3./ /A GGIY"B>> :aDGr>Q.2q8q&z2JJ$$_q%89  :A GGIscAL%+J%:E7L%2J57L%? L%% J2.L%1J22L%5L"ALL%L""L%%L>c ddl}|jd}|jdddddd |jd d d ddd |j\}}t |dkDr&|j dt jdt jj}t jj}t |dkDr|d}t |dkDr|d}|jrh|jrOt|tr t|d}n2t!t j"ddt jdt||y|jrOt|tr t|d}n2t!t j"ddt jdt%||y)Nrz'usage: %prog [-d] [-t] [input [output]])usagez-dz--decoderzDecode (instead of encode)?F store_true)desthelpdefaultactionz-tz--texttextz2data is text, encoded format unix-compatible text?r8zincorrect number of argumentsr9rz: cannot do -t to stdoutrz: cannot do -t from stdin)optparse OptionParser add_option parse_argsr+errorrexitrrr'rrZrrr%printargvr)r[parseroptionsargsinputoutputs rtestrhsm(  " ")R " SF dJX uf <<%%UD)chhqk#>? ufr__main__)NN)NNF) r,rrwarnings _deprecatedr __all__ Exceptionrrrrhr rrrnsi4  Xg. ' I 77tHT$L zFr