-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #111 from lsst-ts/tickets/DM-41258
DM-41258: Implement towncrier is ts_observatory_control.
- Loading branch information
Showing
7 changed files
with
181 additions
and
71 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
name: Enforce Rebasing | ||
|
||
on: | ||
pull_request: | ||
types: [assigned, opened, synchronize, reopened, labeled, unlabeled] | ||
branches-ignore: | ||
- main | ||
|
||
jobs: | ||
rebase_job: | ||
runs-on: ubuntu-latest | ||
name: Enforce rebasing | ||
|
||
steps: | ||
- name: Check out code | ||
uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 0 | ||
- name: Is Rebased on develop? | ||
uses: cyberark/enforce-rebase@v2 | ||
with: | ||
default-branch: develop |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
name: ChangelogUpdated | ||
on: | ||
pull_request: | ||
types: [assigned, opened, synchronize, reopened, labeled, unlabeled] | ||
|
||
jobs: | ||
build: | ||
name: Check for new news fragments | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: Set up python | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: '3.11' | ||
|
||
- name: Install towncrier | ||
run: | | ||
$CONDA/bin/conda install -c conda-forge towncrier -y | ||
- name: Run towncrier check command | ||
run: | | ||
$CONDA/bin/towncrier check --compare-with origin/develop --config pyproject.toml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Integrate towncrier for release notes and change log management. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
Recording Changes | ||
================= | ||
|
||
This directory contains "news fragments" which are small, structured text files that contain information about changes or updates that will be included in the release notes. | ||
These fragments are used to automatically generate changelogs or release notes. | ||
They can be written restructured text format or plain text. | ||
|
||
Each file should be named like ``<JIRA TICKET>.<TYPE>.<EXT>`` with a file extension defining the markup format (``rst|md``). | ||
The ``<TYPE>`` should be one of: | ||
|
||
* ``feature``: A new feature | ||
* ``bugfix``: A bug fix. | ||
* ``perf``: A performance enhancement. | ||
* ``doc``: A documentation improvement. | ||
* ``removal``: A deprecation or removal of API. | ||
* ``misc``: Other minor changes and/or additions | ||
|
||
An example file name would therefore look like ``DM-40534.doc.rst``. | ||
|
||
Each developer now has to create the news fragments for the changes they have made on their own branches, | ||
instead of adding them to the release notes directly. | ||
The news fragments are then automatically integrated into the release notes by the ``towncrier`` tool. | ||
|
||
You can test how the content will be integrated into the release notes by running ``towncrier build --draft --version=v<X.XX.X>``. | ||
Note that you have to run it from the root repository directory (i.e. the ``ts_observatory_control``). | ||
|
||
In order to update the release notes file for real, the person responsible for the release should run: | ||
|
||
.. code-block:: bash | ||
$ towncrier build --version=v<X.XX.X> | ||
.. note:: | ||
|
||
When running towncrier to build the changelog, you may be prompted to confirm the deletion of fragments. | ||
If you would like to retain the fragments in the doc/news directory do not confirm the deletion. | ||
|
||
Note also that ``towncrier`` can be installed from PyPI or conda-forge. |
Oops, something went wrong.