PyScaffold is a template tool designed to quickly set up the scaffold of a Python project, following best practices and integrating with tools like setuptools_scm for version management, tox for testing, and pre-commit for quality control. It is currently at version 4.6 and typically releases minor or patch updates every few months, ensuring compatibility and incorporating improvements.
pip install pyscaffoldVerified import paths — ran on the pinned version, not inferred.
Create a new project named 'my_new_project'. Navigate into the directory, install the project in editable mode with development and test dependencies, then run tests using tox.
Manually migrate any custom configuration files from `~/Library/Preferences/PyScaffold` to `~/Library/Application Support/PyScaffold`.
Ensure your environment uses Python 3.7+ (e.g., `python3.x -m pip install pyscaffold` where `x >= 7`).
Update your extension code to use `importlib.resources.files` for resource access, e.g., `importlib.resources.files('my_package').joinpath('data.txt').read_text()`.Prefer using `tox` versions outside of the 4.0-4.1 range or upgrade PyScaffold to v4.4 or newer to ensure the generated `tox.ini` template handles this automatically.
Ensure PyScaffold is installed (`pip install pyscaffold`) and that your Python environment's script directory is included in your system's PATH. If using `pipx`, ensure `pipx ensurepath` has been run.
If you intend to overwrite the directory, add the `--force` flag: `putup my_project --force`. Otherwise, choose a different project name.
First, ensure the extension package is installed (e.g., `pip install pyscaffoldext-xyz`). Then, verify the extension name is correct (e.g., `putup my_project --extension some_extension`). Check PyScaffold's documentation or PyPI for available extensions and their exact names.