setup

Usage:

Create ~/.pypirc with info:

[distutils] index-servers =

pypi

[pypi] repository: https://upload.pypi.org/legacy/ username: … password: …

(Not needed anymore) Registering the project: python3 setup.py register New release: python3 setup.py sdist upload

I had some trouble at some point, and this helped: pip3 install –user twine python3 setup.py sdist twine upload dist/*.tar.gz

See also MANIFEST.in for included files.

For debugging this script:

python3 setup.py sdist pip3 install –user dist/*.tar.gz -v (Without -v, all stdout/stderr from here will not be shown.)

setup.debug_print_file(fn)[source]
Parameters:fn (str) –
setup.parse_pkg_info(fn)[source]
Parameters:fn (str) –
Return type:dict[str,str]
setup.git_commit_rev(commit='HEAD', git_dir='.')[source]
Parameters:
  • commit (str) –
  • git_dir (str) –
Return type:

str

setup.git_is_dirty(git_dir='.')[source]
Parameters:git_dir (str) –
Return type:bool
setup.git_commit_date(commit='HEAD', git_dir='.')[source]
Parameters:
  • commit (str) –
  • git_dir (str) –
Return type:

str

setup.git_head_version(git_dir='.')[source]
Parameters:git_dir (str) –
Return type:str
setup.main()[source]

Setup main entry