%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /usr/local/lib/python2.7/distutils/command/
Upload File :
Create Path :
Current File : //usr/local/lib/python2.7/distutils/command/upload.pyo

ó
Pêáac@sÞdZddlZddlZddlZddlmZmZmZddlm	Z	ddl
Z
ddlZddl
mZddlmZmZddlmZddlmZdd	lmZd
efd„ƒYZdS(s`distutils.command.upload

Implements the Distutils 'upload' subcommand (upload package to PyPI).iÿÿÿÿN(turlopentRequestt	HTTPError(tstandard_b64encode(tmd5(tDistutilsErrortDistutilsOptionError(t
PyPIRCCommand(tspawn(tlogtuploadcBsUeZdZejddgZejdgZd„Zd„Zd	„Zd
„Z	RS(
supload binary package to PyPItsigntsssign files to upload using gpgs	identity=tisGPG identity used to sign filescCs>tj|ƒd|_d|_d|_t|_d|_dS(Nti(	Rtinitialize_optionstusernametpasswordt
show_responsetFalseRtNonetidentity(tself((s4/usr/local/lib/python2.7/distutils/command/upload.pyRs
				cCsªtj|ƒ|jr/|jr/tdƒ‚n|jƒ}|ikr~|d|_|d|_|d|_|d|_	n|jr¦|j
jr¦|j
j|_ndS(Ns.Must use --sign for --identity to have meaningRRt
repositorytrealm(Rtfinalize_optionsRRRt_read_pypircRRRRtdistribution(Rtconfig((s4/usr/local/lib/python2.7/distutils/command/upload.pyR&s



cCsX|jjs!d}t|ƒ‚nx0|jjD]"\}}}|j|||ƒq.WdS(NsHMust create and upload files in one command (e.g. setup.py sdist upload)(Rt
dist_filesRtupload_file(Rtmsgtcommandt	pyversiontfilename((s4/usr/local/lib/python2.7/distutils/command/upload.pytrun8s
c"Cs`tj|jƒ\}}}}}}	|s6|s6|	rLtd|jƒ‚n|dEkrktd|ƒ‚n|jr¾ddd|g}
|jr¨d|jg|
d	d	+nt|
d
|jƒnt|dƒ}z|jƒ}Wd|j	ƒX|j
j}
idd
6dd6|
jƒd6|
j
ƒd6tjj|ƒ|fd6|d6|d6t|ƒjƒd6dd6|
jƒd6|
jƒd6|
jƒd6|
jƒd6|
jƒd6|
jƒd6|
jƒd6|
jƒd6|
jƒd 6|
jƒd!6|
jƒd"6|
jƒd#6|
jƒd$6}d%}|d&krRt j!ƒ\}}}|rwd'||f}qwn%|d(krwd)t j d*d+ƒ}n||d,<|jr½tjj|ƒd-t|d-ƒjƒf|d.<nd/t"|j#d0|j$ƒ}d1}d2|}|d3}t%j%ƒ}x»|j&ƒD]­\}}t'|t(ƒs5|g}nxƒ|D]{}t'|t)ƒrld4|d5}|d+}nd%}|j*|ƒ|j*d6|ƒ|j*|ƒ|j*d7ƒ|j*|ƒq<WqW|j*|ƒ|j+ƒ}|j,d8||jft-j.ƒid9|d:6t/t0|ƒƒd;6|d<6}t1|jd=|d>|ƒ}yjt2|ƒ}|j3ƒ}|j4}|j5r§d?j6d@dA|jƒd@dAfƒ} |j,| t-j.ƒnWnVt7j8k
rÜ}!|j,t/|!ƒt-j9ƒ‚n%t:k
r}!|!j;}|!j4}nX|dBkr-|j,dC||ft-j.ƒn/dD||f} |j,| t-j9ƒt<| ƒ‚dS(FNsIncompatible url %sthttpthttpssunsupported schema tgpgs
--detach-signs-as--local-useritdry_runtrbtfile_uploads:actiont1tprotcol_versiontnametversiontcontenttfiletypeR!t
md5_digests1.0tmetadata_versiontsummaryt	home_pagetauthortauthor_emailtlicensetdescriptiontkeywordstplatformtclassifierstdownload_urltprovidestrequirest	obsoletesRt	bdist_rpmsbuilt for %s %st
bdist_dumbsbuilt for %stterseitcomments.asct
gpg_signaturesBasic t:s3--------------GHSKFJDLGDS7543FJKLFHRE75642756743254s
--s--
s;filename="%s"is+
Content-Disposition: form-data; name="%s"s

sSubmitting %s to %ss multipart/form-data; boundary=%ssContent-typesContent-lengtht
Authorizationtdatatheaderss
t-iKiÈsServer response (%s): %ssUpload failed (%s): %s(R$R%(=turlparseRtAssertionErrorRRRR'topentreadtcloseRtmetadatatget_nametget_versiontostpathtbasenameRt	hexdigesttget_descriptiontget_urltget_contacttget_contact_emailtget_licencetget_long_descriptiontget_keywordst
get_platformstget_classifierstget_download_urltget_providestget_requirest
get_obsoletesR9tdistRRRtStringIOtitemst
isinstancetlistttupletwritetgetvaluetannounceR	tINFOtstrtlenRRtgetcodeRRtjointsocketterrortERRORRtcodeR("RR R!R"tschematnetlocturltparamstqueryt	fragmentstgpg_argstfR.tmetaRFRBRbR-tidtauthtboundarytsep_boundarytend_boundarytbodytkeytvaluetfnRGtrequesttresulttstatustreasonRte((s4/usr/local/lib/python2.7/distutils/command/upload.pyR@sÂ$			















	 







 
			&	

(RRssign files to upload using gpg(s	identity=R
sGPG identity used to sign files(
t__name__t
__module__R7Rtuser_optionstboolean_optionsRRR#R(((s4/usr/local/lib/python2.7/distutils/command/upload.pyR
s
			(t__doc__RQRpR9turllib2RRRtbase64RRIt	cStringIORcthashlibRtdistutils.errorsRRtdistutils.coreRtdistutils.spawnRt	distutilsR	R
(((s4/usr/local/lib/python2.7/distutils/command/upload.pyt<module>s

Zerion Mini Shell 1.0