Skip to content

Commit

Permalink
chore: Add release tagging script
Browse files Browse the repository at this point in the history
Add simple release tagging script. Should help
avoid accidental typos.
  • Loading branch information
riddell-stan committed Jun 3, 2021
1 parent 0ab878b commit 3cb19f6
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions scripts/tag-release
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
#!/bin/bash
set -euo pipefail

KEYID=85107A96512971B8C55932085D5D0CFF0A51A83D

# check that "Bump version" appears in most recent commit
git log -1 | grep -q -s version

VERSION=$(grep '^version' pyproject.toml | sed 's/version = "\([^"]\+\)"/\1/')
read -r -p "About to create tag for $VERSION. Abort with control-c."
git tag -s -u "$KEYID" "$VERSION" -m"pystan $VERSION"
echo "Commit tagged. Next step is to push the tag upstream. Run something like the following:"
echo -e "\ngit push upstream $VERSION\n"

0 comments on commit 3cb19f6

Please sign in to comment.