File tree Expand file tree Collapse file tree
{{cookiecutter.project_name}} Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ [bumpversion]
2+ current_version = {{ cookiecutter.version }}
3+
4+ [comment]
5+ comment = The contents of this file cannot be merged with that of setup.cfg until https://github.com/c4urself/bump2version/issues/185 is resolved
6+
7+ [bumpversion:file:{{ cookiecutter.package_name }}/__version__.py]
8+ search = __version__ = " {current_version}"
9+ replace = __version__ = " {new_version}"
10+
11+ [bumpversion:file:setup.cfg]
12+ search = version = {current_version}
13+ replace = version = {new_version}
14+
15+ [bumpversion:file:CITATION.cff]
16+ search = version: " {current_version}"
17+ replace = version: " {new_version}"
Original file line number Diff line number Diff line change @@ -105,8 +105,9 @@ help you decide which tool to use for packaging.
105105## Package version number
106106
107107- We recommend using [ semantic versioning] ( https://guide.esciencecenter.nl/#/best_practices/releases?id=semantic-versioning ) .
108- - For convenience, the package version is stored in a single place: ` {{ cookiecutter.package_name }}/__version__.py ` .
109- For updating the version number, you only have to change this file.
108+ - For convenience, the package version is stored in a single place: ` {{ cookiecutter.project_name }}/.bumpversion.cfg ` .
109+ For updating the version number, make sure the dev dependencies are installed and run ` bumpversion patch ` ,
110+ ` bumpversion minor ` , or ` bumpversion major ` as appropriate.
110111- Don't forget to update the version number before [ making a release] ( https://guide.esciencecenter.nl/#/best_practices/releases ) !
111112
112113## Publish on Python Package Index (PyPI)
Original file line number Diff line number Diff line change 33# - https://setuptools.readthedocs.io/en/latest/userguide/declarative_config.html
44# - https://www.python.org/dev/peps/pep-0314/
55
6-
76[metadata]
87author = {{ cookiecutter.full_name }}
98author_email = {{ cookiecutter.email }}
@@ -32,23 +31,21 @@ project_urls =
3231url = {{ cookiecutter.repository }}
3332version = {{ cookiecutter.version }}
3433
35-
3634[options]
3735zip_safe = False
3836include_package_data = True
3937packages =
4038 {{ cookiecutter.package_name }}
4139install_requires =
4240
43-
4441[options.data_files]
4542# This section requires setuptools>=40.6.0
4643# It remains empty for now
4744# Check if MANIFEST.in works for your purposes
4845
49-
5046[options.extras_require]
5147dev =
48+ bump2version
5249 prospector[with_pyroma]
5350 yapf
5451 isort
@@ -61,12 +58,10 @@ dev =
6158 sphinx_rtd_theme
6259 recommonmark
6360
64-
6561[coverage:run]
6662branch = True
6763source = {{ cookiecutter.package_name }}
6864
69-
7065[tool:isort]
7166lines_after_imports = 2
7267force_single_line = 1
@@ -75,7 +70,8 @@ known_first_party = {{ cookiecutter.package_name }}
7570src_paths = {{ cookiecutter.package_name }},tests
7671line_length = 120
7772
78-
7973[tool:pytest]
8074testpaths = tests
75+ # Note that visual debugger in some editors like pycharm gets confused by coverage calculation.
76+ # As a workaround, configure the test configuration in pycharm et al with a --no-cov argument
8177addopts = --cov --cov-report xml --cov-report term --cov-report html
You can’t perform that action at this time.
0 commit comments