git-cliff
git-cliff copied to clipboard
fix(config): default to empty header and footer (#1161)
Description
This PR removes the default values for changelog.header and changelog.footer in config/cliff.toml. This allows users to not have a header and/or footer if they so choose.
Warning: Users that don't have headers and/or footers defined in their own config but want them will have to update their config after this change has been released. They should add the following settings to return to the previous behaviour:
[changelog]
# A Tera template to be rendered as the changelog's footer.
# See https://keats.github.io/tera/docs/#introduction
header = """
# Changelog\n
All notable changes to this project will be documented in this file.\n
"""
# A Tera template to be rendered as the changelog's footer.
# See https://keats.github.io/tera/docs/#introduction
footer = """
<!-- generated by git-cliff -->
"""
Note: The fixtures use different methods of newline handling in their body templates. We should investigate means of standardizing this going forward.
Motivation and Context
The changes introduced in #1087 resulted in changelog.header and changelog.footer being set to predefined templates. This resulted in #1161.
How Has This Been Tested?
Ran all fixtures.
Screenshots / Logs (if applicable)
Types of Changes
- [x] Bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds functionality)
- [x] Breaking change (fix or feature that would cause existing functionality to change)
- [ ] Documentation (no code change)
- [ ] Refactor (refactoring production code)
- [ ] Other
Checklist:
- [x] My code follows the code style of this project.
- [ ] I have updated the documentation accordingly. (does not apply)
- [ ] I have formatted the code with rustfmt. (does not apply)
- [ ] I checked the lints with clippy. (does not apply)
- [ ] I have added tests to cover my changes. (does not apply)
- [x] All new and existing tests passed.
Codecov Report
All modified and coverable lines are covered by tests :white_check_mark:
Project coverage is 41.95%. Comparing base (
deb29dc) to head (0a5fa8e).
Additional details and impacted files
@@ Coverage Diff @@
## main #1172 +/- ##
=======================================
Coverage 41.95% 41.95%
=======================================
Files 21 21
Lines 1981 1981
=======================================
Hits 831 831
Misses 1150 1150
| Flag | Coverage Δ | |
|---|---|---|
| unit-tests | 41.95% <ø> (ø) |
Flags with carried forward coverage won't be shown. Click here to find out more.
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
:rocket: New features to boost your workflow:
- :snowflake: Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
- :package: JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.