a ÕDOgáã@sDdZddlZddlmZddlmZddlmZGdd„deƒZdS)zudistutils.command.install_scripts Implements the Distutils 'install_scripts' command, for installing Python scripts.éN)ÚCommand)Úlog)ÚST_MODEc@sHeZdZdZgd¢ZddgZdd„Zdd„Zd d „Zd d „Z d d„Z dS)Úinstall_scriptsz%install scripts (Python or otherwise)))z install-dir=Údzdirectory to install scripts to)z build-dir=Úbz'build directory (where to install from))ÚforceÚfz-force installation (overwrite existing files))ú skip-buildNzskip the build stepsrr cCsd|_d|_d|_d|_dS)Nr)Ú install_dirrÚ build_dirÚ skip_build©Úself©rúF/opt/alt/python39/lib64/python3.9/distutils/command/install_scripts.pyÚinitialize_optionssz"install_scripts.initialize_optionscCs | dd¡| dddd¡dS)NZbuild)Ú build_scriptsr Zinstall)rr )rr)r r )Zset_undefined_optionsrrrrÚfinalize_options!s  ýz install_scripts.finalize_optionscCs‚|js| d¡| |j|j¡|_tjdkr~| ¡D]H}|j rLt   d|¡q4t  |¡t dBd@}t   d||¡t ||¡q4dS)NrÚposixzchanging mode of %simiÿzchanging mode of %s to %o)r Z run_commandZ copy_treer r ÚoutfilesÚosÚnameÚ get_outputsZdry_runrÚinfoÚstatrÚchmod)rÚfileÚmoderrrÚrun)s   zinstall_scripts.runcCs |jjp gS©N)Z distributionZscriptsrrrrÚ get_inputs8szinstall_scripts.get_inputscCs |jpgSr )rrrrrr;szinstall_scripts.get_outputsN) Ú__name__Ú __module__Ú __qualname__Z descriptionZ user_optionsZboolean_optionsrrrr!rrrrrrsr) Ú__doc__rZdistutils.corerZ distutilsrrrrrrrrÚs