--- freem/scripts/fmd-setversion 2025/04/04 18:00:01 1.1
+++ freem/scripts/fmd-setversion 2025/05/02 16:25:46 1.4
@@ -1,7 +1,7 @@
#!/usr/bin/env bash
#
-# $Id: fmd-setversion,v 1.1 2025/04/04 18:00:01 snw Exp $
+# $Id: fmd-setversion,v 1.4 2025/05/02 16:25:46 snw Exp $
# Set version in FreeM repository
#
#
@@ -25,6 +25,15 @@
# along with FreeM. If not, see .
#
# $Log: fmd-setversion,v $
+# Revision 1.4 2025/05/02 16:25:46 snw
+# -m
+#
+# Revision 1.3 2025/04/06 03:38:05 snw
+# Prepare for adding packaging functionality to fmd
+#
+# Revision 1.2 2025/04/04 19:43:18 snw
+# Switch to using environment catalog to determine user and group for environment, and remove -u and -g flags from freem
+#
# Revision 1.1 2025/04/04 18:00:01 snw
# *** empty log message ***
#
@@ -33,15 +42,30 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
#
-if [[ $# == 0 ]]
+function usage()
+{
+ echo
+ echo "Sets the FreeM version in this repository"
+ echo
+ echo "usage:"
+ echo
+ echo " fmd setversion "
+ echo " - Sets the FreeM version in this repository to "
+ echo
+ echo " fmd setversion --revert"
+ echo " - Reverts to the previous FreeM version"
+ echo
+ exit 0
+}
+
+if [[ $1 == "help" ]]
then
- echo "setversion: must be run from 'fmd setversion'"
- exit 1
+ usage
fi
-if [[ ! -f sem.ver ]]
+if [[ $# == 0 ]]
then
- echo "Not in the root of the FreeM repository."
+ echo "setversion: must be run from 'fmd setversion'"
exit 1
fi
@@ -76,6 +100,7 @@ echo "${NEWVER}" > sem.ver
sed -i.orig "s/${CURVER}/${NEWVER}/g" doc/freem.texi
sed -i.orig "s/${CURVER}/${NEWVER}/g" configure.ac
+sed -i.orig "s/${CURVER}/${NEWVER}/g" doc/freem_conformance.1
VERSTR="VERSION ${NEWVER}"
@@ -84,7 +109,7 @@ echo '**********************************
echo "${VERSTR}" >> ChangeLog
echo "" >> ChangeLog
-${FMD} log "Changed version from ${CURVER} to ${NEWVER}"
+${FMD} log "Change version from ${CURVER} to ${NEWVER}"
${FMD} changelog ${NEWVER}