-
Notifications
You must be signed in to change notification settings - Fork 137
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Release script to make life a bit easier
- Loading branch information
1 parent
a845f71
commit 8bc6d48
Showing
3 changed files
with
29 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
"""Pact version info.""" | ||
|
||
__version__ = '1.0.0' | ||
__version__ = '0.22.0' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
#!/bin/bash | ||
|
||
VERSION=$1 | ||
|
||
if [[ $VERSION =~ ^[0-9]+\.[0-9]+\.[0-9]*$ ]]; then | ||
echo "Updating version $VERSION." | ||
else | ||
echo "Invalid version number $VERSION" | ||
exit 1; | ||
fi | ||
|
||
TAG_NAME="v$VERSION" | ||
|
||
echo "Releasing $TAG_NAME" | ||
|
||
echo -e "`git log --pretty=format:' * %h - %s (%an, %ad)' $TAG_NAME..HEAD`\n$(cat CHANGELOG.md)" > CHANGELOG.md | ||
|
||
echo "Appended Changelog to $VERSION" | ||
|
||
git add CHANGELOG.md pact/__version__.py | ||
git commit -m "Releasing version $VERSION" | ||
|
||
git tag -a "$TAG_NAME" -m "Releasing version $VERSION" | ||
|
||
# && git push origin master --tags` | ||
|
||
|