ok

Mini Shell

Direktori : /lib64/python2.7/Tools/scripts/
Upload File :
Current File : //lib64/python2.7/Tools/scripts/classfix.pyo

�
�fc@s�ddlZddlZddlZddlTejjZeZejjZ	d�Z
ejd�Zd�Z
d�Zd�ZdZeje�Zd	Zeje�Zd
�Zedkr�e
�ndS(i����N(t*cCs�d}tjds<tdtjdd�tjd�nx}tjdD]n}tjj|�rzt|�r�d}q�qJtjj|�r�t|d�d}qJt	|�rJd}qJqJWtj|�dS(Niisusage: s file-or-directory ...
is": will not process symbolic links
(
tsystargvterrtexittostpathtisdirtrecursedowntislinktfix(tbadtarg((s./usr/lib64/python2.7/Tools/scripts/classfix.pytmain)s
	
s^[a-zA-Z0-9_]+\.py$cCstj|�dkS(Ni(tispythonprogtmatch(tname((s./usr/lib64/python2.7/Tools/scripts/classfix.pytispython9scCs1td|f�d}ytj|�}Wn+tjk
rW}td||f�dSX|j�g}x�|D]�}|tjtjfkr�qontjj	||�}tjj
|�r�qotjj|�r�|j|�qot
|�rot|�rd}qqoqoWx#|D]}t|�rd}qqW|S(Nsrecursedown(%r)
is%s: cannot list directory: %r
i(tdbgRtlistdirterrorRtsorttcurdirtpardirRtjoinR	RtappendRR
R(tdirnameRtnamestmsgtsubdirsRtfullname((s./usr/lib64/python2.7/Tools/scripts/classfix.pyR<s0



cCs�yt|d�}Wn(tk
r=}td||f�dSXtjj|�\}}tjj|d|�}d}d}xG|j�}|s�Pn|d}x>|ddkr�|j�}	|	s�Pn||	}|d}q�Wt	|�}
|
|kr�|dkrryt|d�}Wn2tk
rJ}|j
�td	||f�dSX|jd�d}t|d
�q~ntt
|�d�td|�td
|
�n|dk	r~|j|
�q~q~W|j
�|s�dSy+tj|�}tj||td@�Wn*tjk
r0}td||f�nXytj||d�Wn*tjk
ru}td||f�nXytj||�Wn+tjk
r�}td||f�dSXdS(Ntrs%s: cannot open: %r
it@ii����s\
tws%s: cannot create: %r
s:
s
s< s> i�s%s: warning: chmod failed (%r)
t~s %s: warning: backup failed (%r)
s%s: rename failed (%r)
(topentIOErrorRRRtsplitRtNonetreadlinetfixlinetclosetseektreptreprtwritetstattchmodtST_MODERtrename(tfilenametfRtheadttailttempnametgtlinenotlinetnextlinetnewlinetstatbuf((s./usr/lib64/python2.7/Tools/scripts/classfix.pyR
Rsp




s-^([ 	]*class +[a-zA-Z0-9_]+) *( *) *((=.*)?):s^ *(.*) *( *) *$cCstj|�dkr|Stjd \\}}\}}\}}|| }||}||krm|d|S||d|!}	|	jd�}
x^tt|
��D]J}tj|
|�dkr�tjd\}}
|
|||
!|
|<q�q�Wdj|
�}	|d|	d|S(	Niit:it,s, t(s):(t	classprogRtregsR%trangetlentbaseprogR(R9ta0tb0ta1tb1ta2tb2R4R5tbaseparttbasestitx1ty1((s./usr/lib64/python2.7/Tools/scripts/classfix.pyR(�s(

t__main__(RtreRR.tstderrR-RRtstdoutR+R
tcompileRRRR
t	classexprR@tbaseexprRDR(t__name__(((s./usr/lib64/python2.7/Tools/scripts/classfix.pyt<module> s$
				E	

Zerion Mini Shell 1.0