Skip to content

Commit

Permalink
release: officially adopt Keep a Changelog
Browse files Browse the repository at this point in the history
We are already using the format so might as well link to where it comes
from.

Also adjust the release-notes.sh line to account for 5 additional lines
at the top.

Signed-off-by: Pablo Barbáchano <pablob@amazon.com>
  • Loading branch information
pb8o committed Dec 6, 2023
1 parent 3fb0368 commit dc552f5
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Changelog

All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [Unreleased]

### Added
Expand Down
3 changes: 2 additions & 1 deletion tools/release-notes.sh
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,8 @@ changelog="$FC_ROOT_DIR/CHANGELOG.md"

# Patterns for the sections in the changelog corresponding to the versions.
pat_curr="/^##\s\[$curr_ver\]/"
pat_prev="/^##\s\[.+]/ && NR>3"
# Match the previous version, skipping the 8 lines at the top.
pat_prev="/^##\s\[.+]/ && NR>8"
# Extract the section enclosed between the 2 headers and strip off the first
# 2 and last 2 lines (one is blank and one contains the header `## [A.B.C]`).
# Then, replace `-` with `*` and remove section headers.
Expand Down

0 comments on commit dc552f5

Please sign in to comment.