Repository URL to install this package:
|
Version:
0.1.31 ▾
|
odigos-demo-inventory
/
opt
/
odigos-demo-inventory
/
site-packages
/
pkginfo
/
__pycache__
/
commandline.cpython-311.pyc
|
|---|
§
hµµh÷ ã ó" d Z ddlmZ ddlmZ ddlmZ ddlZddlZddl Z ddl
Z
ddlmZ ddZ
G d d
e¦ « Z G d de¦ « Z G d
de¦ « Z G d de¦ « Z G d de¦ « Z G d de¦ « ZeeeeedZddZdS )ap Print the metadata for one or more Python package distributions.
Usage: %prog [options] path+
Each 'path' entry can be one of the following:
o a source distribution: in this case, 'path' should point to an existing
archive file (.tar.gz, .tar.bz2, or .zip) as generated by 'setup.py sdist'.
o a binary distribution: in this case, 'path' should point to an existing
archive file (.egg)
o a "develop" checkout: in this case, 'path' should point to a directory
initialized via 'setup.py develop' (under setuptools).
o an installed package: in this case, 'path' should be the importable name
of the package.
é )ÚConfigParser)ÚOrderedDict)ÚwriterNé )Úget_metadatac ó2 t j t ¬¦ « }| ddd d¬¦ « | dddd d
¬¦ « | dd
dd¬¦ « | dddddd¬¦ « | dddddd¬¦ « | dddd d!¬¦ « | d"ddd#d$¬%¦ « | d&d'd(d)d*¬¦ « | d+d,d(d-d.¬¦ « | d/ddd0d1¬%¦ « | d2ddd3d4¬%¦ « | d5ddd6d7¬%¦ « | | ¦ « \ }} t | ¦ « d8k r| d9¦ « d S || fS ):N)Úusagez-mz--metadata-versionzOverride metadata version)ÚdefaultÚhelpz-fz--fieldÚfieldsÚappendz$Specify an output field (repeatable))ÚdestÚactionr z-dz--download-url-prefixÚdownload_url_prefixzDownload URL prefix)r r z--simpleÚoutputÚstore_constÚsimplez Output as simple key-value pairs)r r Úconstr
r z-sz--skipÚskipÚ
store_trueTz$Skip missing values in simple output)r r r
r z-Sz --no-skipÚstore_falsez*Don't skip missing values in simple outputz--singleÚsinglezOutput delimited values)r r r r z--item-delimÚ
item_delimÚstoreú;z*Delimiter for fields in single-line outputz--sequence-delimÚsequence_delimú,z!Delimiter for multi-valued fieldsz--csvÚcsvz
Output as CSVz--iniÚiniz
Output as INIz--jsonÚjsonzOutput as JSONr z3Pass one or more files or directories as arguments.)ÚoptparseÚOptionParserÚ__doc__Ú
add_optionÚ
parse_argsÚlenÚerror)ÚargsÚparserÚoptionss ú>/usr/local/lib/python3.11/site-packages/pkginfo/commandline.pyÚ_parse_optionsr, sc Ý
Ô
"Ð
1Ñ
1Ô
1Fà
×ÒdÐ0¸$Ø6ð ñ 8ô 8ð 8ð ×ÒdI¨H¸XØAð ñ ô ð ð ×ÒdÐ3Ø0Ø0ð ñ ô ð ð
×Òj x¸
Ø$¨hØ=ð ñ ô ð ð
×ÒdH¨6¸,Ø"ØAð ñ ô ð ð
×ÒdK¨f¸]ØGð ñ ô ð ð ×Òj x¸
Ø$Ø4ð ñ ô ð ð
×Òn¨<ÀØ!ØGð ñ ô ð ð
×ÒÐ(Ð/?Ø$¨cØ>ð ñ ô ð ð
×Òg H°]Ø!Ø*ð ñ ô ð ð
×Òg H°]Ø!Ø*ð ñ ô ð ð
×Òh X°mØ"Ø+ð ñ ô ð ð
×%Ò% dÑ+Ô+MGTå
4yy!||ØÐJÑKÔKÐKÐKÐKà}Ðó c ó e Zd ZdZd Zd ZdS )ÚBaseNc ó0 |j r|j | _ d S d S ©N)r Ú_fields)Úselfr* s r+ Ú__init__z
Base.__init__b s# Ø>ð *Ø">DLLLð *ð *r- c ó d S r1 © ©r3 s r+ ÚfinishzBase.finishf s Ør- )Ú__name__Ú
__module__Ú__qualname__r2 r4 r8 r6 r- r+ r/ r/ ` s7 ØGð*ð *ð *ð
ð
ð
ð
ð
r- r/ c ó$ e Zd Z fdZd Z xZS )ÚSimplec óp t t | ¦ « |¦ « |j | _ d S r1 )Úsuperr= r4 r Ú_skip©r3 r* Ú __class__s r+ r4 zSimple.__init__j s. ø Ý
fdÑÔ×$Ò$ WÑ-Ô-Ð-Ø\
r- c ó | j pt |¦ « D ]5}t ||¦ « }| j r||dk rt |d|¦ « 6d S )Nr6 z: )r2 ÚlistÚgetattrr@ Úprint©r3 ÚmetaÚfieldÚvalues r+ Ú__call__zSimple.__call__n sh Ø\Ð/¥T¨$¡Z¤Zð 1ð 1EÝD %Ñ(Ô(EØJð
1 EÐ$5¸%Àº)¸)Ý % % %¨¨Ð/Ñ0Ô0Ð0øð 1ð 1r- )r9 r: r; r4 rK Ú
__classcell__©rB s @r+ r= r= i sG ø ð"ð "ð "ð "ð "ð1ð 1ð 1ð 1ð 1ð 1ð 1r- r= c ó( e Zd ZdZ fdZd Z xZS )Ú
SingleLineNc ó t t | ¦ « |¦ « |j | _ |j | _ d S r1 )r? rO r4 r Ú_item_delimr Ú_sequence_delimrA s r+ r4 zSingleLine.__init__v s= ø Ý
j$ÑÔ×(Ò(¨Ñ1Ô1Ð1Ø"Ô-ÔØ&Ô5ÔÐÐr- c óx | j t |¦ « | _ g }| j D ]m}t ||¦ « }t |t t f¦ « r| j |¦ « }nt |¦ « }| |¦ « nt | j
|¦ « ¦ « d S r1 )r2 rD rE Ú
isinstanceÚtuplerR ÚjoinÚstrr
rF rQ )r3 rH ÚvaluesrI rJ s r+ rK zSingleLine.__call__{ s¯ Ø<ÐÝ ::DLØØ\ð !ð !EÝD %Ñ(Ô(EÝ%¥% Ñ/Ô/ð
#ØÔ,×1Ò1°%Ñ8Ô8åE
ØMM%Ñ Ô Ð Ð Ý
dÔ×#Ò# FÑ+Ô+Ñ,Ô,Ð,Ð,Ð,r- )r9 r: r; r2 r4 rK rL rM s @r+ rO rO t sL ø ØGð6ð 6ð 6ð 6ð 6ð
-ð -ð -ð -ð -ð -ð -r- rO c ó( e Zd ZdZ fdZd Z xZS )ÚCSVNc óp t t | ¦ « |¦ « |j | _ d S r1 )r? rZ r4 r rR rA s r+ r4 zCSV.__init__ s2 ø Ý
c4ÑÔ×!Ò! 'Ñ*Ô*Ð*Ø&Ô5ÔÐÐr- c óà | j t |¦ « | _ | j }| j 8t t j ¦ « | _ | j |¦ « g }|D ]m}t ||¦ « }t |t t f¦ « r| j
|¦ « }nt |¦ « }|
|¦ « n| j |¦ « d S r1 )r2 rD Ú_writerr ÚsysÚstdoutÚwriterowrE rT rU rR rV rW r
)r3 rH r rX rI rJ s r+ rK zCSV.__call__ sÚ Ø<ÐÝ ::DLØØ<ÐÝ!¥#¤*Ñ-Ô-DLØL×!Ò! &Ñ)Ô)Ð)ØØð !ð !EÝD %Ñ(Ô(EÝ%¥% Ñ/Ô/ð
#ØÔ,×1Ò1°%Ñ8Ô8åE
ØMM%Ñ Ô Ð Ð Ø×ÒfÑ%Ô%Ð%Ð%Ð%r- )r9 r: r; r] r4 rK rL rM s @r+ rZ rZ sL ø ØGð6ð 6ð 6ð 6ð 6ð&ð &ð &ð &ð &ð &ð &r- rZ c ó. e Zd ZdZ fdZd Zd Z xZS )ÚININc ó~ t t | ¦ « |¦ « t ¦ « | _ d S r1 )r? rb r4 r Ú_parserrA s r+ r4 zINI.__init__¡ s0 ø Ý
c4ÑÔ×!Ò! 'Ñ*Ô*Ð*Ý#~~r- c ó¨ |j }|j }|d|}| j |¦ « rt d|z ¦ « | j |¦ « | j pt |¦ « D ]_}t ||¦ « }t |t t f¦ « rd |¦ « }| j |||¦ « `d S )Nú-zDuplicate distribution: %sz
)
ÚnameÚversionrd Úhas_sectionÚ
ValueErrorÚadd_sectionr2 rD rE rT rU rV Úset)r3 rH rg rh ÚsectionrI rJ s r+ rK zINI.__call__¥ sÜ ØyØ,Ø!TT 7 7Ð+Ø<×#Ò# GÑ,Ô,ð EÝÐ9¸GÑCÑDÔDÐDØ× Ò Ñ)Ô)Ð)Ø\Ð/¥T¨$¡Z¤Zð 4ð 4EÝD %Ñ(Ô(EÝ%¥% Ñ/Ô/ð
+Ø EÑ*Ô*ØL×ÒW e¨UÑ3Ô3Ð3Ð3ð 4ð 4r- c óN | j t j ¦ « d S r1 )rd Úwriter^ r_ r7 s r+ r8 z
INI.finish² s Ø×Ò3:Ñ&Ô&Ð&Ð&Ð&r- ©r9 r: r; r2 r4 rK r8 rL rM s @r+ rb rb s[ ø ØGð&ð &ð &ð &ð &ð4ð 4ð 4ð'ð 'ð 'ð 'ð 'ð 'ð 'r- rb c ó. e Zd ZdZ fdZd Zd Z xZS )ÚJSONNc ó~ t t | ¦ « |¦ « t ¦ « | _ d S r1 )r? rr r4 r Ú_mappingrA s r+ r4 z
JSON.__init__· s0 ø Ý
dDÑÔ×"Ò" 7Ñ+Ô+Ð+Ý#
r- c ó, | j t |¦ « | _ | j D ]p}t ||¦ « }|r+t |t t f¦ « st |¦ « }|| j v rt dt ¦ « z ¦ « || j |<