ӰnD0 d dl Z d dlZd dlmZ d dlmZ d dlmZ d dlmZ d dlm Z d dlm Z d dlmZ d d l mZ d d lmZ d dlmZ d dlmZmZ d Z G d de ZdS ) N)glob)warn)Command)dir_util) file_util)archive_util)TextFile)FileList)log)convert_path)DistutilsTemplateErrorDistutilsOptionErrorc ddl m} ddlm} g }| D ])}| d|z d || d f *| | | d d S )Nr )FancyGetopt)ARCHIVE_FORMATSformats= z.List of available source distribution formats:)distutils.fancy_getoptr distutils.archive_utilr keysappendsort print_help)r r formatsformats >/opt/alt/python311/lib64/python3.11/distutils/command/sdist.pyshow_formatsr s 322222666666G!&&(( 5 5 V+T'/24 5 5 5 5LLNNNK##8: : : : : c e Zd ZdZd Zg dZg dZdddefgZdd d Z defgZ dZd Zd Z d Zd Zd Zd Zed Zd Zd Zd Zd Zd Zd Zd Zd Zd Zd Zd Zd Zd Z d! Z!d" Z"dS )#sdistz6create a source distribution (tarball, zip file, etc.)c | j S N)metadata_checkselfs r checking_metadatazsdist.checking_metadata( s 3 ""r ))z template=tz5name of manifest template file [default: MANIFEST.in])z manifest=mz)name of manifest file [default: MANIFEST])use-defaultsNzRinclude the default file set in the manifest [default; disable with --no-defaults])no-defaultsNz"don't include the default file set)pruneNzspecifically exclude files/directories that should not be distributed (build tree, RCS/CVS dirs, etc.) [default; disable with --no-prune])no-pruneNz$don't automatically exclude anything) manifest-onlyozEjust regenerate the manifest and then stop (implies --force-manifest))force-manifestfzkforcibly regenerate the manifest and carry on as usual. Deprecated: now the manifest is always regenerated.)r Nz6formats for source distribution (comma-separated list)) keep-tempkz@keep the distribution tree around after creating archive file(s))z dist-dir=dzFdirectory to put the source distribution archive(s) in [default: dist])metadata-checkNz[Ensure that all required elements of meta-data are supplied. Warn if any missing. [default])zowner=uz@Owner name used when creating a tar file [default: current user])zgroup=gzAGroup name used when creating a tar file [default: current group])r) r+ r- r/ r1 r4 zhelp-formatsNz#list available distribution formatsr) r+ )r* r, check)READMEz README.txtz README.rstc d | _ d | _ d| _ d| _ d| _ d| _ dg| _ d| _ d | _ d | _ d| _ d | _ d | _ d S )N r gztar) templatemanifestuse_defaultsr+ manifest_onlyforce_manifestr keep_tempdist_dir archive_filesr# ownergroupr$ s r initialize_optionszsdist.initialize_optionse sl y ! r c | j d| _ | j d| _ | d t j | j }|rt d|z | j d| _ d S d S )NMANIFESTzMANIFEST.inr zunknown archive format '%s'dist)r= r<