Skip to content

Commit

Permalink
add towncrier news
Browse files Browse the repository at this point in the history
  • Loading branch information
ms-wise committed May 24, 2022
1 parent ad4bc03 commit 1740e95
Show file tree
Hide file tree
Showing 8 changed files with 57 additions and 8 deletions.
1 change: 1 addition & 0 deletions .changelog/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
!.gitignore
36 changes: 36 additions & 0 deletions .changelog/template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
{% if top_line %}
{{ top_line }}
{{ top_underline * ((top_line)|length)}}
{% elif versiondata.name %}
{{ versiondata.name }} {{ versiondata.version }} ({{ versiondata.date }})
{{ top_underline * ((versiondata.name + versiondata.version + versiondata.date)|length + 4)}}
{% else %}
{{ versiondata.version }} ({{ versiondata.date }})
{{ top_underline * ((versiondata.version + versiondata.date)|length + 3)}}
{% endif %}
{% for section, _ in sections.items() %}
{%- if section %}{{section}}{% endif -%}

{% if sections[section] %}
{% for category, val in definitions.items() if category in sections[section]%}
### {{ definitions[category]['name'] }}

{% if definitions[category]['showcontent'] %}
{% for text, values in sections[section][category].items() %}
- {{ values|join(', ') }} {{ text }}
{% endfor %}
{% else %}
- {{ sections[section][category]['']|join(', ') }}
{% endif %}
{% if sections[section][category]|length == 0 %}
No significant changes.

{% else %}
{% endif %}

{% endfor %}
{% else %}
No significant changes.

{% endif %}
{% endfor %}
Empty file added CHANGELOG.md
Empty file.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,15 +38,15 @@ To build by source, call a [PEP517](https://peps.python.org/pep-0517) compliant
python -m build
```

For more details, please visit [INSTALLATION](https://mikesongming.github.io/SE-Geometry/user-guide/installation).
For more details, please visit [INSTALLATION](https://mikesongming.github.io/SE-Geometry/user-guide/install/).

# Contributors

**众人拾柴火焰高** :

- Mike Song, <gnosoir@hotmail.com>

More contributors and sponsors are welcome. Please visit [CONTRIBUTING](https://mikesongming.github.io/SE-Geometry/user-guide/contributing) for details.
More contributors and sponsors are welcome. Please visit [CONTRIBUTING](https://mikesongming.github.io/SE-Geometry/about/contributing/) for details.


# License
Expand Down
1 change: 0 additions & 1 deletion changes/.gitignore

This file was deleted.

7 changes: 3 additions & 4 deletions docs/about/history.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
# towncrier generated
# <center><small>empowered by</small> [@Towncrier](https://towncrier.readthedocs.io/en/latest/)</center>


~~~rst
{%
include "../../NEWS.rst"
include-markdown "../../CHANGELOG.md"
%}
~~~
2 changes: 1 addition & 1 deletion docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
A library on sun position and sunlight analysis from the observer's viewpoint,
which comsists of a simplistic _python_ frontend and an extensible _C++_ backend.

[Get Started](https://mikesongming.github.io/SE-Geometry/user-guide/getting-started/){ .md-button .md-button--primary }
[Get Started](https://mikesongming.github.io/SE-Geometry/user-guide/install/){ .md-button .md-button--primary }


## Features & Algorithms
Expand Down
14 changes: 14 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -68,3 +68,17 @@ markers = [
"mpi: mark tests for mpi implementation",
"gpu: mark tests for gpu implementation",
]

# Towncrier section
# Read more here: https://towncrier.readthedocs.io/en/latest/configuration.html
[tool.towncrier]
# version = "1.2.3" ## to be given as cmd args
# name="FSEG"
filename = "CHANGELOG.md"
directory = ".changelog/news"
template = ".changelog/template.md"
title_format = "## v{version} ({project_date})"
issue_format = "[#{issue}](https://github.com/mikesongming/SE-Geometry/issues/{issue})"
start_string = "<!-- TOWNCRIER -->\n"
underlines = ["", "", ""]
wrap=true

0 comments on commit 1740e95

Please sign in to comment.