ConfigurationΒΆ

Projects set up with PyScaffold feature an easy package configuration with setup.cfg. Check out the example below as well as pbr’s usage manual.

[metadata]
name = my_project
summary = A test project that was set up with PyScaffold
author = Florian Wilhelm
author-email = Florian.Wilhelm@blue-yonder.com
license = new BSD
home-page = http://...
description-file = README.rst
# Add here all kinds of additional classifiers as defined under
# https://pypi.python.org/pypi?%3Aaction=list_classifiers
classifier =
    Development Status :: 5 - Production/Stable
    Topic :: Utilities
    Programming Language :: Python
    Programming Language :: Python :: 2
    Programming Language :: Python :: 2.7
    Programming Language :: Python :: 3
    Programming Language :: Python :: 3.4
    Programming Language :: Python :: 3.5
    Environment :: Console
    Intended Audience :: Developers
    License :: OSI Approved :: BSD License
    Operating System :: POSIX :: Linux
    Operating System :: Unix
    Operating System :: MacOS
    Operating System :: Microsoft :: Windows

[entry_points]
# Add here console scripts like:
console_scripts =
    run_my_project = my_project.cli:run
# as well as other entry_points.

[files]
# Add here 'data_files', 'packages' or 'namespace_packages'.
# Additional data files are defined as key value pairs of source and target:
packages =
    my_project
data_files =
    share/my_project/docs = docs/*

[extras]
# Add here additional requirements for extra features, like:
# PDF =
#    ReportLab>=1.2
#    RXP
ALL =
    django
    cookiecutter

[test]
# py.test options when running `python setup.py test`
addopts = tests

[pytest]
# Options for py.test:
# Specify command line options as you would do when invoking py.test directly.
# e.g. --cov-report html (or xml) for html/xml output or --junitxml junit.xml
# in order to write a coverage file that can be read by Jenkins.
addopts =
    --cov my_project --cov-report term-missing
    --verbose

[aliases]
docs = build_sphinx

[bdist_wheel]
# Use this option if your package is pure-python
universal = 1

[build_sphinx]
# Options for Sphinx build
source_dir = docs
build_dir = docs/_build

[pbr]
# Let pbr run sphinx-apidoc
autodoc_tree_index_modules = True
# autodoc_tree_excludes = ...
# Let pbr itself generate the apidoc
# autodoc_index_modules = True
# autodoc_exclude_modules = ...
# Convert warnings to errors
# warnerrors = True

[devpi:upload]
# Options for the devpi: PyPI server and packaging tool
# VCS export must be deactivated since we are using setuptools-scm
no-vcs = 1
formats = bdist_wheel