Radish alpha
H
rad:z3QDZAW2FAfuLvihrhiyDC9fAD8G9
HardenedBSD Package Manager
Radicle
Git
When creating a snapshot based on eg. pkg-1.1 (ie. with a patch level of 0) then explicitly show the zero patchlevel. Otherwise a snapshot -- pkg-1.1.20121222 -- would appear as a higher version than the next patch release -- pkg-1.1.1. With this change the snapshot would be pkg-1.1.0.20121222
Matthew Seaman committed 13 years ago
commit 63a7343cf01d2e74bfc3d3f071c7d050c4bc5700
parent e4e6b8e
1 file changed +12 -5
modified newvers.sh
@@ -44,14 +44,22 @@
: ${PORTREVISION:=}
: ${PORTEPOCH:=}

-
# Define this to a true value if creating a snapshot
-
: ${CREATE_SNAPSHOT:="NO"}
-

# ------------------------------------------------------------------

+
# Define this to a true value in the environment if creating a
+
# snapshot
+
: ${CREATE_SNAPSHOT:="NO"}
+

case $PKG_PATCH_LEVEL in
    ''|0)
-
	_patch=
+
	case $CREATE_SNAPSHOT in
+
	    [yY][eE][sS])
+
		_patch=".${PKG_PATCH_LEVEL}"
+
		;;
+
	    *)
+
		_patch=
+
		;;
+
	esac
	;;
    *)
	_patch=".${PKG_PATCH_LEVEL}"
@@ -110,4 +118,3 @@ esac
#
# That's All Folks!
#
-