ok

Mini Shell

Direktori : /proc/self/root/proc/self/root/proc/thread-self/root/usr/lib64/python2.7/Demo/pdist/
Upload File :
Current File : //proc/self/root/proc/self/root/proc/thread-self/root/usr/lib64/python2.7/Demo/pdist/RCSProxy.pyc

�
V
�Qc@s�dZddlZddlZddlZddlZddlZddlZddlZddd��YZdej	efd��YZ
de
ejfd��YZd	�Z
d
�Zedkr�e�ndS(
sRCS Proxy.

Provide a simplified interface on RCS files, locally or remotely.
The functionality is geared towards implementing some sort of
remote CVS like utility.  It is modeled after the similar module
FSProxy.

The module defines two classes:

RCSProxyLocal  -- used for local access
RCSProxyServer -- used on the server side of remote access

The corresponding client class, RCSProxyClient, is defined in module
rcsclient.

The remote classes are instantiated with an IP address and an optional
verbosity flag.
i����Nt
DirSupportcBseeZd�Zd�Zd�Zd�Zd�Zd�Zd
d�Z	d�Z
d�Zd	�ZRS(cCs
g|_dS(N(t	_dirstack(tself((s+/usr/lib64/python2.7/Demo/pdist/RCSProxy.pyt__init__!scCs|j�dS(N(t_close(R((s+/usr/lib64/python2.7/Demo/pdist/RCSProxy.pyt__del__$scCsx|jr|j�qWdS(N(Rtback(R((s+/usr/lib64/python2.7/Demo/pdist/RCSProxy.pyR'scCs
tj�S(N(tostgetcwd(R((s+/usr/lib64/python2.7/Demo/pdist/RCSProxy.pytpwd+scCs-tj�}tj|�|jj|�dS(N(RRtchdirRtappend(Rtnametsave((s+/usr/lib64/python2.7/Demo/pdist/RCSProxy.pytcd.s
cCs@|jstjd�n|jd}tj|�|jd=dS(Nsempty directory stacki����(RRterrorR
(Rtdir((s+/usr/lib64/python2.7/Demo/pdist/RCSProxy.pyR3s
	

cCs7tjtj�}ttjj|�}|j||�S(N(Rtlistdirtcurdirtfiltertpathtisdirt_filter(Rtpattfiles((s+/usr/lib64/python2.7/Demo/pdist/RCSProxy.pytlistsubdirs:scCstjj|�S(N(RRR(RR((s+/usr/lib64/python2.7/Demo/pdist/RCSProxy.pyR?scCstj|d�dS(Ni�(Rtmkdir(RR((s+/usr/lib64/python2.7/Demo/pdist/RCSProxy.pyRBscCstj|�dS(N(Rtrmdir(RR((s+/usr/lib64/python2.7/Demo/pdist/RCSProxy.pyREsN(
t__name__t
__module__RRRR	RRtNoneRRRR(((s+/usr/lib64/python2.7/Demo/pdist/RCSProxy.pyRs								t
RCSProxyLocalcBsheZd�Zd�Zd	d�Zd	d�Zd�Zd�Zd	d�Z	d	d�Z
d	d�ZRS(
cCs!tjj|�tj|�dS(N(trcslibtRCSRR(R((s+/usr/lib64/python2.7/Demo/pdist/RCSProxy.pyRKscCs!tj|�tjj|�dS(N(RRR R!(R((s+/usr/lib64/python2.7/Demo/pdist/RCSProxy.pyROs
cCs|j|j|�S(N(t_listtsum(Rtlist((s+/usr/lib64/python2.7/Demo/pdist/RCSProxy.pytsumlistSscCs|j|j|�S(N(t_dictR#(RR$((s+/usr/lib64/python2.7/Demo/pdist/RCSProxy.pytsumdictVscCsd|j|�}d}tj�}x)|j|�}|s=Pn|j|�q$|j|�|j�S(Niii (t_opentmd5tnewtreadtupdatet
_closepipetdigest(Rtname_revtft
BUFFERSIZER#tbuffer((s+/usr/lib64/python2.7/Demo/pdist/RCSProxy.pyR#Ys
cCs,|j|�}|j�}|j|�|S(N(R(R+R-(RR/R0tdata((s+/usr/lib64/python2.7/Demo/pdist/RCSProxy.pytgetes
cCs\|j|�\}}t|d�}|j|�|j�|j||�|j|�dS(Ntw(t	_unmangletopentwritetclosetcheckint_remove(RR/R3tmessageRtrevR0((s+/usr/lib64/python2.7/Demo/pdist/RCSProxy.pytputks

cCs�|dkr|j�}ng}x[|D]S}y|j|||�f�Wq(tjtfk
rz|j|df�q(Xq(W|S(s�INTERNAL: apply FUNCTION to all files in LIST.

        Return a list of the results.

        The list defaults to all files in the directory if None.

        N(Rt	listfilesRRRtIOError(RtfunctionR$tresR((s+/usr/lib64/python2.7/Demo/pdist/RCSProxy.pyR"ss
cCsg|dkr|j�}ni}x?|D]7}y||�||<Wq(tjtfk
r^q(Xq(W|S(s�INTERNAL: apply FUNCTION to all files in LIST.

        Return a dictionary mapping files to results.

        The list defaults to all files in the directory if None.

        N(RR?RRR@(RRAR$tdictR((s+/usr/lib64/python2.7/Demo/pdist/RCSProxy.pyR&�s
N(RRRRRR%R'R#R4R>R"R&(((s+/usr/lib64/python2.7/Demo/pdist/RCSProxy.pyRIs				tRCSProxyServercBs)eZejd�Zd�Zd�ZRS(cCs'tj|�tjj|||�dS(N(RRtservertSecureServer(Rtaddresstverbose((s+/usr/lib64/python2.7/Demo/pdist/RCSProxy.pyR�s
cCs!tjj|�tj|�dS(N(RERFRR(R((s+/usr/lib64/python2.7/Demo/pdist/RCSProxy.pyR�scCs.tjj|�x|jr)|j�qWdS(N(RERFt_serveRR(R((s+/usr/lib64/python2.7/Demo/pdist/RCSProxy.pyRI�s(RRREtVERBOSERRRI(((s+/usr/lib64/python2.7/Demo/pdist/RCSProxy.pyRD�s	cCsdddl}ddl}|jdr>|j|jd�}nd}td|f�}|j�dS(Ni����iit(tstringtsystargvtatoiRDt_serverloop(RLRMtporttproxy((s+/usr/lib64/python2.7/Demo/pdist/RCSProxy.pyttest_server�s
cCs�ddl}|jds>|jdrU|jdddkrUt�|jd�nt�}|jd}t||�r�t||�}t|�r�t|t	|jd��GHq�t
|�GHnd|GH|jd�dS(Ni����iit
0123456789is%s: no such attribute(RMRNRStexitRthasattrtgetattrtcallabletapplyttupletrepr(RMRRtwhattattr((s+/usr/lib64/python2.7/Demo/pdist/RCSProxy.pyttest�s2	
	t__main__((t__doc__RER)RtfnmatchRLttempfileR RR!RRFRDRSR^R(((s+/usr/lib64/python2.7/Demo/pdist/RCSProxy.pyt<module>s*O		

Zerion Mini Shell 1.0