Skip to content

Commit 60e1244

Browse files
committed
Configure and add Towncrier files
* Add changelog.d/.gitignore to keep this directory * Create changelog.d/README.rst with some descriptions * Add changelog.d/_template.rst as Towncrier template * Add [tool.towncrier] section in pyproject.toml * Add "changelog" target into `tox.ini`. Use it like "tox -e changes -- CMD" whereas CMD is a towncrier command. The default "tox -e changes" calls towncrier to create a draft of the changelog file and output it to stdout. * Update documentation and add include a new section "Changelog" included from changelog.d/README.rst
1 parent e2532b2 commit 60e1244

File tree

10 files changed

+272
-2
lines changed

10 files changed

+272
-2
lines changed

CHANGELOG.rst

Lines changed: 74 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,19 @@ Change Log
66
All notable changes to this code base will be documented in this file,
77
in every released version.
88

9+
Changes for the upcoming release can be found in
10+
the `"changelog.d" directory <https://github.com/python-semver/python-semver/tree/master/changelog.d>`_
11+
in our repository.
12+
13+
..
14+
Do *NOT* add changelog entries here!
15+
16+
This changelog is managed by towncrier and is compiled at release time.
17+
18+
See https://www.attrs.org/en/latest/contributing.html#changelog for details.
19+
20+
.. towncrier release notes start
21+
922
1023
Version 2.10.2
1124
==============
@@ -32,13 +45,17 @@ Additions
3245
n/a
3346

3447
Deprecations
35-
--------
48+
------------
3649

3750
* :gh:`160` (:pr:`264`):
3851
* :func:`semver.max_ver`
3952
* :func:`semver.min_ver`
4053

4154

55+
----
56+
57+
58+
4259
Version 2.10.1
4360
==============
4461

@@ -62,6 +79,9 @@ Bug Fixes
6279
to always return a ``VersionInfo`` instance.
6380

6481

82+
----
83+
84+
6585
Version 2.10.0
6686
==============
6787

@@ -92,7 +112,7 @@ Additions
92112

93113

94114
Deprecations
95-
--------
115+
------------
96116
* :gh:`225` (:pr:`229`): Output a DeprecationWarning for the following functions:
97117

98118
- ``semver.parse``
@@ -109,6 +129,8 @@ Deprecations
109129
These deprecated functions will be removed in semver 3.
110130

111131

132+
----
133+
112134

113135
Version 2.9.1
114136
=============
@@ -135,6 +157,8 @@ Bug Fixes
135157
* :gh:`192` (:pr:`193`): Fixed "pysemver" and "pysemver bump" when called without arguments
136158

137159

160+
----
161+
138162
Version 2.9.0
139163
=============
140164
:Released: 2019-10-30
@@ -178,13 +202,16 @@ Removals
178202
* :gh:`148` (:pr:`149`): Removed and replaced ``python setup.py test``
179203

180204

205+
----
206+
181207
Version 2.8.2
182208
=============
183209
:Released: 2019-05-19
184210
:Maintainer: Sébastien Celles <s.celles@gmail.com>
185211

186212
Skipped, not released.
187213

214+
----
188215

189216
Version 2.8.1
190217
=============
@@ -206,6 +233,8 @@ Bug Fixes
206233
* :gh:`96` (:pr:`97`): Made VersionInfo immutable
207234

208235

236+
----
237+
209238
Version 2.8.0
210239
=============
211240
:Released: 2018-05-16
@@ -230,6 +259,9 @@ Removals
230259
* :gh:`76` (:pr:`80`): Removed Python 2.6 compatibility
231260

232261

262+
----
263+
264+
233265
Version 2.7.9
234266
=============
235267

@@ -243,6 +275,8 @@ Additions
243275
* :gh:`65` (:pr:`66`): Added :func:`semver.finalize_version` function.
244276

245277

278+
----
279+
246280
Version 2.7.8
247281
=============
248282

@@ -252,6 +286,8 @@ Version 2.7.8
252286
* :gh:`62`: Support custom default names for pre and build
253287

254288

289+
----
290+
255291
Version 2.7.7
256292
=============
257293

@@ -262,6 +298,8 @@ Version 2.7.7
262298
* :pr:`56`: Added support for Python 3.6
263299

264300

301+
----
302+
265303
Version 2.7.2
266304
=============
267305

@@ -286,6 +324,8 @@ Bug Fixes
286324
the prerelease version.
287325

288326

327+
----
328+
289329
Version 2.6.0
290330
=============
291331

@@ -301,6 +341,8 @@ Removals
301341
ignored in comparisons.
302342

303343

344+
----
345+
304346
Version 2.5.0
305347
=============
306348

@@ -318,6 +360,8 @@ Changes
318360
* Made separate builds for tests on Travis CI.
319361

320362

363+
----
364+
321365
Version 2.4.2
322366
=============
323367

@@ -336,6 +380,8 @@ Changes
336380
* Added configuration for Tox test runner.
337381

338382

383+
----
384+
339385
Version 2.4.1
340386
=============
341387

@@ -348,6 +394,8 @@ Additions
348394
* :gh:`23`: Compared build component of a version.
349395

350396

397+
----
398+
351399
Version 2.4.0
352400
=============
353401

@@ -360,6 +408,8 @@ Bug Fixes
360408
* :gh:`21`: Compared alphanumeric components correctly.
361409

362410

411+
----
412+
363413
Version 2.3.1
364414
=============
365415

@@ -372,6 +422,8 @@ Additions
372422
* Declared granted license name in distribution metadata.
373423

374424

425+
----
426+
375427
Version 2.3.0
376428
=============
377429

@@ -385,6 +437,8 @@ Additions
385437
version.
386438

387439

440+
----
441+
388442
Version 2.2.1
389443
=============
390444

@@ -397,6 +451,8 @@ Bug Fixes
397451
* Corrected comparison when any component includes zero.
398452

399453

454+
----
455+
400456
Version 2.2.0
401457
=============
402458

@@ -411,6 +467,8 @@ Additions
411467
* Add code examples for recently-added functions.
412468

413469

470+
----
471+
414472
Version 2.1.2
415473
=============
416474

@@ -423,6 +481,8 @@ Bug Fixes
423481
* Restored current README document to distribution manifest.
424482

425483

484+
----
485+
426486
Version 2.1.1
427487
=============
428488

@@ -435,6 +495,8 @@ Bug Fixes
435495
* Removed absent document from distribution manifest.
436496

437497

498+
----
499+
438500
Version 2.1.0
439501
=============
440502

@@ -463,6 +525,8 @@ Bug Fixes
463525
* Corrected code examples in README document.
464526

465527

528+
----
529+
466530
Version 2.0.2
467531
=============
468532

@@ -477,6 +541,8 @@ Additions
477541
* Explicitly declared supported Python versions.
478542

479543

544+
----
545+
480546
Version 2.0.1
481547
=============
482548

@@ -489,6 +555,8 @@ Bug Fixes
489555
* :gh:`9`: Fixed comparison of equal version strings.
490556

491557

558+
----
559+
492560
Version 2.0.0
493561
=============
494562

@@ -508,6 +576,8 @@ Changes
508576
* Ignore build component for comparison.
509577

510578

579+
----
580+
511581
Version 0.0.2
512582
=============
513583

@@ -520,6 +590,8 @@ Changes
520590
* Use standard library Distutils for distribution management.
521591

522592

593+
----
594+
523595
Version 0.0.1
524596
=============
525597

changelog.d/.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
!.gitignore

changelog.d/236.deprecation.rst

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
Output a DeprecationWarning for the following functions:
2+
3+
* ``semver.compare``
4+
* ``semver.match``
5+
* ``semver.max_ver``
6+
* ``semver.min_ver``

changelog.d/270.feature.rst

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
:gh:`270`: Use towncrier to build ``CHANGELOG.rst`` file
2+
See ``changelog.d/README.rst`` for details.

changelog.d/README.rst

Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
1+
The ``changelog.d`` Directory
2+
=============================
3+
4+
.. -text-begin-
5+
6+
A "Changelog" is a record of all notable changes made to a project. Such
7+
a changelog, in our case the :file:`CHANGELOG.rst`, is read by our *users*.
8+
Therefor, any description should be aimed to users instead of describing
9+
internal changes which are only relevant to developers.
10+
11+
To avoid merge conflicts, we use the towncrier_ package to manage our changelog.
12+
13+
The directory :file:`changelog.d` contains "newsfragments" which are short
14+
ReST-formatted files.
15+
On release, those news fragments are compiled into our :file:`CHANGELOG.rst`.
16+
17+
You don't need to install ``towncrier`` yourself, use the :command:`tox` command
18+
to call the tool.
19+
20+
We recommend to follow the steps to make a smooth integration of your changes:
21+
22+
#. After you have created a new pull request (PR), add a new file into the
23+
directory :file:`changelog.d`. Each filename follows the syntax::
24+
25+
<ISSUE>.<TYPE>.rst
26+
27+
where ``<ISSUE>`` is the pull request number, and ``<TYPE>`` is one of:
28+
29+
* ``bugfix``: fixes a reported bug.
30+
* ``deprecation``: informs about deprecation warnings
31+
* ``doc``: improves documentation.
32+
* ``feature``: adds new user facing features.
33+
* ``removal``: removes obsolete or deprecated features.
34+
* ``trivial``: fixes a small typo or internal change that might be noteworthy.
35+
36+
For example: ``123.feature.rst``, ``456.bugfix.rst`` etc.
37+
38+
#. Create the new file with the command::
39+
40+
tox -e changelog -- create 123.feature.rst`
41+
42+
#. Open the file and add describe your changes.
43+
44+
#. Check your changes with::
45+
46+
tox -e changelog -- check
47+
48+
#. Optionally, build a draft version of the changelog file with the command::
49+
50+
tox -e changelog
51+
52+
#. Commit all your changes and push it.
53+
54+
55+
This finishes your steps.
56+
57+
On release, the maintainer compiles a new :file:`CHANGELOG.rst` file by running::
58+
59+
tox -e changelog -- build
60+
61+
This will remove all newsfragments inside the :file:`changelog.d` directory,
62+
making it ready for the next release.
63+
64+
65+
66+
.. _towncrier: https://pypi.org/project/towncrier

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy