-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add release.sh and generating releas notes from git messages
- Loading branch information
bosob
committed
Oct 6, 2020
1 parent
66cf606
commit 2293d2d
Showing
5 changed files
with
42 additions
and
11 deletions.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -35,3 +35,6 @@ nbactions*.xml | |
# Test | ||
.jqwik-database | ||
.attach_pid* | ||
|
||
# Release | ||
.release_notes_*.txt |
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,30 @@ | ||
#!/bin/sh | ||
|
||
if [ -z "$1" ] | ||
then | ||
echo "release version required" | ||
exit 1 | ||
fi | ||
if [ -z "$2" ] | ||
then | ||
echo "new development version required" | ||
exit 1 | ||
fi | ||
release_version=$1 | ||
development_version="$2-SNAPSHOT" | ||
|
||
echo "Start release $release_version by adding tag (see Travis CI)" | ||
git tag -a $release_version -m "Release $release_version" | ||
git push origin $release_version | ||
|
||
echo "Update development version to $development_version" | ||
mvn org.codehaus.mojo:versions-maven-plugin:2.5:set -DnewVersion=$development_version | ||
mvn org.codehaus.mojo:versions-maven-plugin:2.5:commit | ||
git ls-files --modified | grep 'pom\.xml$' | xargs git add | ||
git commit -m "Update development version to $development_version" | ||
|
||
echo "Release notes by git commit message generated (see .release_notes_$release_version.txt" | ||
git log $(git describe --tags --abbrev=0)..HEAD --pretty=format:"%s" -i -E --grep="^\s*(\[FEATURE\]|\[FIX\])]" > .release_notes_"$release_version".txt | ||
#git log $(git describe --tags --abbrev=0)..HEAD --pretty=format:"%s" -i -E --grep="^\s*(\[INTERNAL\]|\[FEATURE\]|\[FIX\]|\[DOC\])*(\[FEATURE\]|\[FIX\])]" > .release_notes_"$release_version".txt | ||
|
||
echo "Please commit and push the change with 'git push origin' and update release notes in GitHub!" |
This file was deleted.
Oops, something went wrong.
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