Python tool for helping making shorter and smarter setup.py scripts
Project description
Extended SetupTools
Python tool for helping in making shorter and smarter setup.py scripts.
Features
- Automatically extracts application meta-info from the root
__init__.pyfile:- Name
- Version
- License
- Automatically finds packages
- Finds and attaches ReadMe file
- Handles requirements files and maps to the respective
requiressetup arguments:setup_requires:setup-requirements.txtandrequirements/setup-requirements.txtinstall_requires:requirements.txtandrequirements/requirements.txttests_require:test-requirements.txtandrequirements/test-requirements.txtextras_require:requirements/requirements-*.txt- Also creates extras
allthat contains all available features
- Creates test runner with HTML reports
- Inserts link to the repository as the homepage
Usage
Modern Style
In your pyproject.toml, add the following:
[build-system]
requires = [ 'setuptools', 'extended-setup-tools >= 0.2.2' ]
build-backend = 'setuptools.build_meta'
Legacy Style
Install package:
python -m pip install extended-setup-tools
Instead of installing to the current scope,
it is possible to install this package as setup_requires step:
from setuptools import _install_setup_requires
_install_setup_requires(dict(setup_requires=[ 'extended-setup-tools' ]))
src/python_package_name/__init__.py
from collections import namedtuple
__title__ = 'my-package'
__author__ = 'Peter Zaitcev / USSX Hares'
__license__ = 'BSD 2-clause'
__copyright__ = 'Copyright 2021 Peter Zaitcev'
__version__ = '0.1.0'
VersionInfo = namedtuple('VersionInfo', 'major minor micro releaselevel serial')
version_info = VersionInfo(*__version__.split('.'), releaselevel='alpha', serial=0)
__all__ = \
[
'version_info',
'__title__',
'__author__',
'__license__',
'__copyright__',
'__version__',
]
setup.py
from extended_setup import ExtendedSetupManager
ExtendedSetupManager('python_package_name').setup \
(
short_description = "Some short description",
classifiers = [ 'Programming Language :: Python :: 3.7' ],
)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file extended_setup_tools-0.2.5.tar.gz.
File metadata
- Download URL: extended_setup_tools-0.2.5.tar.gz
- Upload date:
- Size: 14.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3084be819d1ee6c151db3e84e1a82ef6a3b18d600039055342294384a6a8444d
|
|
| MD5 |
d501c1a1f58f099a2b44eac1f21fd349
|
|
| BLAKE2b-256 |
d6b3060fdd76125cb38e445cbbc2366a397be54d4afed3b43a3a662974ca2d67
|
File details
Details for the file extended_setup_tools-0.2.5-py3-none-any.whl.
File metadata
- Download URL: extended_setup_tools-0.2.5-py3-none-any.whl
- Upload date:
- Size: 13.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
460de37b3ea1825641429a8dc01080da0d6e5035f3ce144c788fc662e7f38fb8
|
|
| MD5 |
7a065c1a0f4357771f592ff64e82d6fc
|
|
| BLAKE2b-256 |
ac928f427ecc23be01dc6a03efd0e68b03487f59a6d3180781445abaa1dc78ca
|