Skip to content

Commit

Permalink
feat(please): bump minor there is in commit
Browse files Browse the repository at this point in the history
  • Loading branch information
adhocore committed Aug 18, 2018
1 parent b864ead commit 944bd2b
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion please
Original file line number Diff line number Diff line change
Expand Up @@ -232,7 +232,10 @@ if [ "" == "$COMMITS" ]; then
fi

# determine next version
if [[ $MAJOR -eq 1 ]]; then
FEAT=`git log "${DIFF}" --oneline --pretty="%s" | grep -P '^feat' || echo ""`
if [[ "" != "$FEAT" ]]; then
NEXT_VERSION=`echo $VERSION | (IFS=".$IFS"; read a b c && echo $a.$((b + 1)).0)`
elif [[ $MAJOR -eq 1 ]]; then
NEXT_VERSION=`echo $VERSION | (IFS=".$IFS"; read a b c && echo $((a + 1)).0.0)`
elif [[ $MINOR -eq 1 ]]; then
NEXT_VERSION=`echo $VERSION | (IFS=".$IFS"; read a b c && echo $a.$((b + 1)).0)`
Expand Down

0 comments on commit 944bd2b

Please sign in to comment.