Skip to content

Commit e9ddc1d

Browse files
committed
git-release: show message if nothing given after --semver
1 parent f5d99bc commit e9ddc1d

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

bin/git-release

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,12 @@ if test $# -gt 0; then
3434
-c) need_changelog=true;;
3535
-r) remote=$2; shift ;;
3636
-m) msg=$2; shift ;;
37-
--semver) semver=$2; shift ;;
37+
--semver)
38+
test -z "$2" &&
39+
exit_with_msg "major/minor/patch required for --semver option"
40+
semver=$2
41+
shift
42+
;;
3843
--no-empty-commit) no_empty_commit=true;;
3944
--) shift; hook_args="$hook_args $*"; break;;
4045
*) test -z "$version" && version=$1 ;;

0 commit comments

Comments
 (0)