diff options
| author | EuAndreh <eu@euandre.org> | 2021-02-28 21:24:08 -0300 |
|---|---|---|
| committer | EuAndreh <eu@euandre.org> | 2021-02-28 21:24:08 -0300 |
| commit | 78540438dab21981da5fdf522e772efe95334736 (patch) | |
| tree | 5c49946d9a28a30e185fe5cc67b94d6dc07f9e10 /aux/workflow | |
| parent | Makefile: Add stub dev-check target (diff) | |
| download | dotfiles-78540438dab21981da5fdf522e772efe95334736.tar.gz dotfiles-78540438dab21981da5fdf522e772efe95334736.tar.xz | |
fake-symlinks: assert-changelog.sh: Iterate on tags instead of getting the tag as an argument
Diffstat (limited to 'aux/workflow')
| -rwxr-xr-x | aux/workflow/assert-changelog.sh | 19 |
1 files changed, 10 insertions, 9 deletions
diff --git a/aux/workflow/assert-changelog.sh b/aux/workflow/assert-changelog.sh index 83d7fe50..d39f5273 100755 --- a/aux/workflow/assert-changelog.sh +++ b/aux/workflow/assert-changelog.sh @@ -1,13 +1,14 @@ #!/bin/sh set -eu -DATE="$1" -VERSION="$2" -VVERSION="v$2" -PROJECT="$3" +PROJECT="$1" -CHANGELOG_ENTRY="# [$VERSION](https://git.euandreh.xyz/$PROJECT/commit/?id=$VVERSION) - $DATE" -if ! grep -qF "$CHANGELOG_ENTRY" CHANGELOG.md; then - echo "Missing '$CHANGELOG_ENTRY' entry from CHANGELOG.md" >&2 - exit 1 -fi +for VVERSION in $(git tag); do + VERSION="${VVERSION#v}" + DATE="$(git log -1 --format=%cd --date=short "$VVERSION")" + CHANGELOG_ENTRY="# [$VERSION](https://git.euandreh.xyz/$PROJECT/commit/?id=$VVERSION) - $DATE" + if ! grep -qF "$CHANGELOG_ENTRY" CHANGELOG.md; then + echo "Missing '$CHANGELOG_ENTRY' entry from CHANGELOG.md" >&2 + exit 1 + fi +done |
