/opt/imh-python/lib/python3.9/distutils/command/__pycache__
NameSizeModeActions
bdist.cpython-39.opt-1.pyc36140644editdlrm
bdist.cpython-39.opt-2.pyc34200644editdlrm
bdist.cpython-39.pyc36140644editdlrm
bdist_dumb.cpython-39.opt-1.pyc35970644editdlrm
bdist_dumb.cpython-39.opt-2.pyc33970644editdlrm
bdist_dumb.cpython-39.pyc35970644editdlrm
bdist_msi.cpython-39.opt-1.pyc197120644editdlrm
bdist_msi.cpython-39.opt-2.pyc181710644editdlrm
bdist_msi.cpython-39.pyc197790644editdlrm
bdist_rpm.cpython-39.opt-1.pyc121840644editdlrm
bdist_rpm.cpython-39.opt-2.pyc118650644editdlrm
bdist_rpm.cpython-39.pyc122340644editdlrm
bdist_wininst.cpython-39.opt-1.pyc85040644editdlrm
bdist_wininst.cpython-39.opt-2.pyc83650644editdlrm
bdist_wininst.cpython-39.pyc85540644editdlrm
build.cpython-39.opt-1.pyc38900644editdlrm
build.cpython-39.opt-2.pyc38070644editdlrm
build.cpython-39.pyc38900644editdlrm
build_clib.cpython-39.opt-1.pyc48090644editdlrm
build_clib.cpython-39.opt-2.pyc42550644editdlrm
build_clib.cpython-39.pyc48090644editdlrm
build_ext.cpython-39.opt-1.pyc162000644editdlrm
build_ext.cpython-39.opt-2.pyc142430644editdlrm
build_ext.cpython-39.pyc162000644editdlrm
build_py.cpython-39.opt-1.pyc103900644editdlrm
build_py.cpython-39.opt-2.pyc91830644editdlrm
build_py.cpython-39.pyc104420644editdlrm
build_scripts.cpython-39.opt-1.pyc43390644editdlrm
build_scripts.cpython-39.opt-2.pyc39450644editdlrm
build_scripts.cpython-39.pyc43390644editdlrm
check.cpython-39.opt-1.pyc49180644editdlrm
check.cpython-39.opt-2.pyc42870644editdlrm
check.cpython-39.pyc49180644editdlrm
clean.cpython-39.opt-1.pyc20910644editdlrm
clean.cpython-39.opt-2.pyc20080644editdlrm
clean.cpython-39.pyc20910644editdlrm
config.cpython-39.opt-1.pyc102210644editdlrm
config.cpython-39.opt-2.pyc68840644editdlrm
config.cpython-39.pyc102210644editdlrm
install.cpython-39.opt-1.pyc135490644editdlrm
install.cpython-39.opt-2.pyc124940644editdlrm
install.cpython-39.pyc135490644editdlrm
install_data.cpython-39.opt-1.pyc22940644editdlrm
install_data.cpython-39.opt-2.pyc21490644editdlrm
install_data.cpython-39.pyc22940644editdlrm
install_egg_info.cpython-39.opt-1.pyc30290644editdlrm
install_egg_info.cpython-39.opt-2.pyc23500644editdlrm
install_egg_info.cpython-39.pyc30290644editdlrm
install_headers.cpython-39.opt-1.pyc17190644editdlrm
install_headers.cpython-39.opt-2.pyc15530644editdlrm
install_headers.cpython-39.pyc17190644editdlrm
install_lib.cpython-39.opt-1.pyc50910644editdlrm
install_lib.cpython-39.opt-2.pyc45100644editdlrm
install_lib.cpython-39.pyc50910644editdlrm
install_scripts.cpython-39.opt-1.pyc21420644editdlrm
install_scripts.cpython-39.opt-2.pyc20080644editdlrm
install_scripts.cpython-39.pyc21420644editdlrm
register.cpython-39.opt-1.pyc84620644editdlrm
register.cpython-39.opt-2.pyc71970644editdlrm
register.cpython-39.pyc84620644editdlrm
sdist.cpython-39.opt-1.pyc144890644editdlrm
sdist.cpython-39.opt-2.pyc111300644editdlrm
sdist.cpython-39.pyc144890644editdlrm
upload.cpython-39.opt-1.pyc52380644editdlrm
upload.cpython-39.opt-2.pyc51120644editdlrm
upload.cpython-39.pyc52380644editdlrm
__init__.cpython-39.opt-1.pyc4840644editdlrm
__init__.cpython-39.opt-2.pyc3750644editdlrm
__init__.cpython-39.pyc4840644editdlrm
Edit: /opt/imh-python/lib/python3.9/distutils/command/__pycache__/sdist.cpython-39.pyc (14489B)
a dæh=Jã@s¸dZddlZddlZddlmZddlmZddlmZddlm Z ddlm Z ddlm Z dd l m Z dd lmZdd lmZdd lmZdd lmZmZdd„ZGdd„deƒZdS)zadistutils.command.sdist Implements the Distutils 'sdist' command (create a source distribution).éN)Úglob)Úwarn)ÚCommand)Údir_util)Ú file_util)Ú archive_util)ÚTextFile)ÚFileList)Úlog)Ú convert_path)ÚDistutilsTemplateErrorÚDistutilsOptionErrorcCs`ddlm}ddlm}g}| ¡D] }| d|d||df¡q$| ¡||ƒ d¡dS)zoPrint all possible values for the 'formats' option (used by the "--help-formats" command-line option). r)Ú FancyGetopt)ÚARCHIVE_FORMATSúformats=Néz.List of available source distribution formats:)Zdistutils.fancy_getoptrZdistutils.archive_utilrÚkeysÚappendÚsortÚ print_help)rrÚformatsÚformat©rú8/opt/imh-python/lib/python3.9/distutils/command/sdist.pyÚ show_formatss     ÿÿrc@seZdZdZdd„Zgd¢Zgd¢ZdddefgZd d d œZ d efgZ d Z dd„Z dd„Z dd„Zdd„Zdd„Zdd„Zedd„ƒZdd„Zdd„Zd d!„Zd"d#„Zd$d%„Zd&d'„Zd(d)„Zd*d+„Zd,d-„Zd.d/„Zd0d1„Zd2d3„Zd4d5„Z d6d7„Z!d8d9„Z"dS):Úsdistz6create a source distribution (tarball, zip file, etc.)cCs|jS)zYCallable used for the check sub-command. Placed here so user_options can view it)Úmetadata_check©ÚselfrrrÚchecking_metadata(szsdist.checking_metadata))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)ÚpruneNz‰specifically 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-onlyÚozEjust regenerate the manifest and then stop (implies --force-manifest))úforce-manifestÚfzkforcibly regenerate the manifest and carry on as usual. Deprecated: now the manifest is always regenerated.)rNz6formats for source distribution (comma-separated list))ú keep-tempÚkz@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(r*r-z help-formatsNz#list available distribution formatsr"r$)r#r%Úcheck)ZREADMEz README.txtz README.rstcCsTd|_d|_d|_d|_d|_d|_dg|_d|_d|_d|_ d|_ d|_ d|_ dS)NérÚgztar) ÚtemplateÚmanifestÚ use_defaultsr$Ú manifest_onlyZforce_manifestrÚ keep_tempÚdist_dirÚ archive_filesrÚownerÚgrouprrrrÚinitialize_optionseszsdist.initialize_optionscCsZ|jdurd|_|jdur d|_| d¡t |j¡}|rFtd|ƒ‚|jdurVd|_dS)NZMANIFESTz MANIFEST.inrzunknown archive format '%s'Údist)r4r3Zensure_string_listrZcheck_archive_formatsrr r8)rZ bad_formatrrrÚfinalize_options|s    ÿ zsdist.finalize_optionscCs>tƒ|_| ¡D]}| |¡q| ¡|jr2dS| ¡dS©N)r ÚfilelistZget_sub_commandsZ run_commandÚ get_file_listr6Úmake_distribution)rZcmd_namerrrÚrunŒs  z sdist.runcCs*tdtƒ|j d¡}| ¡| ¡dS)zDeprecated API.zadistutils.command.sdist.check_metadata is deprecated, use the check command insteadr0N)rÚPendingDeprecationWarningÚ distributionZget_command_objZensure_finalizedrC)rr0rrrÚcheck_metadata¢s ÿ zsdist.check_metadatacCs tj |j¡}|s:| ¡r:| ¡|j ¡|j ¡dS|sN|  d|j¡|j  ¡|j rf|  ¡|rr|  ¡|jr€| ¡|j ¡|j ¡| ¡dS)aCFigure out the list of files to include in the source distribution, and put it in 'self.filelist'. This might involve reading the manifest template (and writing the manifest), or just reading the manifest, or just using the default file set -- it all depends on the user's options. Nz?manifest template '%s' does not exist (using default file list))ÚosÚpathÚisfiler3Ú_manifest_is_not_generatedÚ read_manifestr@rZremove_duplicatesrÚfindallr5Ú add_defaultsÚ read_templater$Úprune_file_listÚwrite_manifest)rZtemplate_existsrrrrAªs(   þ   zsdist.get_file_listcCs<| ¡| ¡| ¡| ¡| ¡| ¡| ¡dS)a9Add all the default files to self.filelist: - README or README.txt - setup.py - test/test*.py - all pure Python modules mentioned in setup script - all files pointed by package_data (build_py) - all files defined in data_files. - all files defined as scripts. - all C sources listed as part of extensions or C libraries in the setup script (doesn't catch C headers!) Warns if (README or README.txt) or setup.py are missing; everything else is optional. N)Ú_add_defaults_standardsÚ_add_defaults_optionalÚ_add_defaults_pythonÚ_add_defaults_data_filesÚ_add_defaults_extÚ_add_defaults_c_libsÚ_add_defaults_scriptsrrrrrMÒszsdist.add_defaultscCs:tj |¡sdStj |¡}tj |¡\}}|t |¡vS)z± Case-sensitive path existence check >>> sdist._cs_path_exists(__file__) True >>> sdist._cs_path_exists(__file__.upper()) False F)rGrHÚexistsÚabspathÚsplitÚlistdir)ÚfspathrYZ directoryÚfilenamerrrÚ_cs_path_existsès  zsdist._cs_path_existscCs–|j|jjg}|D]~}t|tƒrj|}d}|D]"}| |¡r,d}|j |¡qPq,|s| dd  |¡¡q| |¡r‚|j |¡q| d|¡qdS)NFTz,standard file not found: should have one of z, zstandard file '%s' not found) ÚREADMESrEZ script_nameÚ isinstanceÚtupler^r@rrÚjoin)rZ standardsÚfnZaltsZgot_itrrrrQùs"   ÿ zsdist._add_defaults_standardscCs4ddg}|D]"}ttjjt|ƒƒ}|j |¡q dS)Nz test/test*.pyz setup.cfg)ÚfilterrGrHrIrr@Úextend)rZoptionalÚpatternÚfilesrrrrRszsdist._add_defaults_optionalcCs\| d¡}|j ¡r$|j | ¡¡|jD],\}}}}|D]}|j tj   ||¡¡q:q*dS)NÚbuild_py) Úget_finalized_commandrEZhas_pure_modulesr@reÚget_source_filesÚ data_filesrrGrHrb)rrhZpkgZsrc_dirZ build_dirÚ filenamesr]rrrrSs   zsdist._add_defaults_pythoncCsz|j ¡rv|jjD]b}t|tƒrBt|ƒ}tj |¡rt|j   |¡q|\}}|D]$}t|ƒ}tj |¡rN|j   |¡qNqdSr?) rEZhas_data_filesrkr`Ústrr rGrHrIr@r)rÚitemÚdirnamerlr)rrrrT$s     zsdist._add_defaults_data_filescCs(|j ¡r$| d¡}|j | ¡¡dS)NÚ build_ext)rEZhas_ext_modulesrir@rerj)rrprrrrU5s  zsdist._add_defaults_extcCs(|j ¡r$| d¡}|j | ¡¡dS)NÚ build_clib)rEZhas_c_librariesrir@rerj)rrqrrrrV:s  zsdist._add_defaults_c_libscCs(|j ¡r$| d¡}|j | ¡¡dS)NÚ build_scripts)rEZ has_scriptsrir@rerj)rrrrrrrW?s  zsdist._add_defaults_scriptsc Cs¨t d|j¡t|jddddddd}zr| ¡}|dur:qŽz|j |¡Wq(ttfyŠ}z$|  d|j |j |f¡WYd}~q(d}~00q(W|  ¡n |  ¡0dS)zÈRead and parse manifest template file named by self.template. (usually "MANIFEST.in") The parsing and processing is done by 'self.filelist', which updates itself accordingly. zreading manifest template '%s'r1)Zstrip_commentsZ skip_blanksZ join_linesZ lstrip_wsZ rstrip_wsZ collapse_joinNz%s, line %d: %s) r Úinfor3rÚreadliner@Zprocess_template_liner Ú ValueErrorrr]Z current_lineÚclose)rr3ÚlineÚmsgrrrrNDs" þ þ"zsdist.read_templatecCsz| d¡}|j ¡}|jjd|jd|jjd|dtjdkrFd}nd}gd¢}d|d  |¡|f}|jj|d d dS) avPrune off branches that might slip into the file list as created by 'read_template()', but really don't belong there: * the build tree (typically "build") * the release tree itself (only an issue if we ran "sdist" previously with --keep-temp, or it aborted) * any RCS, CVS, .svn, .hg, .git, .bzr, _darcs directories ÚbuildN)ÚprefixÚwin32z/|\\ú/)ÚRCSÚCVSz\.svnz\.hgz\.gitz\.bzrÚ_darcsz(^|%s)(%s)(%s).*ú|r1)Zis_regex) rirEÚ get_fullnamer@Zexclude_patternZ build_baseÚsysÚplatformrb)rryÚbase_dirÚsepsZvcs_dirsZvcs_ptrnrrrrOas   zsdist.prune_file_listcCsX| ¡rt d|j¡dS|jjdd…}| dd¡| tj |j|fd|j¡dS)z²Write the file list in 'self.filelist' (presumably as filled in by 'add_defaults()' and 'read_template()') to the manifest file named by 'self.manifest'. z5not writing to manually maintained manifest file '%s'Nrz*# file GENERATED by distutils, do NOT editzwriting manifest file '%s') rJr rsr4r@rgÚinsertZexecuterZ write_file)rZcontentrrrrPysÿ ÿzsdist.write_manifestcCsDtj |j¡sdSt|jƒ}z| ¡}W| ¡n | ¡0|dkS)NFz+# file GENERATED by distutils, do NOT edit )rGrHrIr4Úopenrtrv)rÚfpZ first_linerrrrJˆs  z sdist._manifest_is_not_generatedcCsjt d|j¡t|jƒ>}|D](}| ¡}| d¡s|s:q|j |¡qWdƒn1s\0YdS)zªRead the manifest file (named by 'self.manifest') and use it to fill in 'self.filelist', the list of files to include in the source distribution. zreading manifest file '%s'ú#N)r rsr4r‡ÚstripÚ startswithr@r)rr4rwrrrrK”s zsdist.read_manifestcCs®| |¡tj|||jdttdƒr4d}d|}n d}d|}|sPt d¡n t |¡|D]<}tj   |¡s|t d|¡q^tj   ||¡}|j |||d q^|j j |¡dS) aÆCreate the directory tree that will become the source distribution archive. All directories implied by the filenames in 'files' are created under 'base_dir', and then we hard link or copy (if hard linking is unavailable) those files into place. Essentially, this duplicates the developer's source tree, but in a directory named after the distribution, containing only the files to be distributed. ©Údry_runÚlinkZhardzmaking hard links in %s...Nzcopying files to %s...z)no files to distribute -- empty manifest?z#'%s' not a regular file -- skipping)rŽ)ZmkpathrZ create_treerÚhasattrrGr rrsrHrIrbZ copy_filerEÚmetadataZwrite_pkg_info)rr„rgrŽrxÚfileÚdestrrrÚmake_release_tree¢s      zsdist.make_release_treecCs¶|j ¡}tj |j|¡}| ||jj¡g}d|j vrT|j   |j   |j   d¡¡¡|j D]:}|j ||||j|jd}|  |¡|jj  dd|f¡qZ||_|js²tj||jddS)a¯Create the source distribution(s). First, we create the release tree with 'make_release_tree()'; then, we create all required archive files (according to 'self.formats') from the release tree. Finally, we clean up by blowing away the release tree (unless 'self.keep_temp' is true). The list of archive files created is stored so it can be retrieved later by 'get_archive_files()'. Útar)r„r:r;rÚrŒN)rErrGrHrbr8r“r@rgrrÚpopÚindexÚ make_archiver:r;Z dist_filesr9r7rZ remove_treer)rr„Ú base_namer9Úfmtr‘rrrrBÌs    ÿ zsdist.make_distributioncCs|jS)zzReturn the list of archive files created when the command was run, or None if the command hasn't run yet. )r9rrrrÚget_archive_filesêszsdist.get_archive_files)#Ú__name__Ú __module__Ú __qualname__Ú descriptionrZ user_optionsZboolean_optionsrZ help_optionsZ negative_optZ sub_commandsr_r<r>rCrFrArMÚ staticmethodr^rQrRrSrTrUrVrWrNrOrPrJrKr“rBr›rrrrr$sH'ÿÿÿ (  *r)Ú__doc__rGr‚rÚwarningsrZdistutils.corerZ distutilsrrrZdistutils.text_filerZdistutils.filelistr r Zdistutils.utilr Zdistutils.errorsr r rrrrrrÚs