Skip to content

Commit

Permalink
ci: check release date of current version in changelog
Browse files Browse the repository at this point in the history
  • Loading branch information
eduardosm committed Apr 21, 2024
1 parent c7801f2 commit edd1d79
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions ci/lint-aux.sh
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,19 @@ if [ "$publish_ok" != "true" ]; then
exit 1
fi

changelog_date="$(awk -v ver="${version%-pre}" '/^## / { if ($2 == ver) print $3 }')"
if [[ "$version" = *-pre ]]; then
if [ "$changelog_date" != "(unreleased)" ]; then
echo "Invalid date in changelog for version $version"
exit 1
fi
else
if [[ ! "$changelog_date" ~= \([0-9]{4}-[0-9]{2}-[0-9]{2}\) ]]; then
echo "Invalid date in changelog for version $version"
exit 1
fi
fi

end_group

begin_group "Check MSRV consistency"
Expand Down

0 comments on commit edd1d79

Please sign in to comment.