mirror of
https://github.com/python/cpython.git
synced 2025-08-03 16:39:00 +00:00
added the generate-setup action
This commit is contained in:
parent
ab244398ba
commit
721ccd0ce1
2 changed files with 18 additions and 2 deletions
|
@ -1087,7 +1087,7 @@ def generate_setup_py():
|
|||
Raises a PackagingFileError when a setup.py already exists.
|
||||
"""
|
||||
if os.path.exists("setup.py"):
|
||||
raise PackagingFileError("a setup.py file alreadyexists")
|
||||
raise PackagingFileError("a setup.py file already exists")
|
||||
|
||||
with open("setup.py", "w", encoding='utf-8') as fp:
|
||||
fp.write(_SETUP_TMPL % {'func': getsource(cfg_to_args)})
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue