Fix bin/cvt-submission - check chkentry version

The minimum version for cvt-submission of chkentry is 1.1.5, the most
recent version.

Technically the previous version would work too but 1.1.5 renamed some
variables to make it more consistent with the mkiocccentry terminology
so it's better to have 1.1.5.
This commit is contained in:
Cody Boone Ferguson committed 2025-02-27 05:05:19 -08:00
1 parent b6cc6406bd
commit c74c76f8b7
1 file changed
+19 -9
+19 -9
View File
@@ -122,15 +122,6 @@ if [[ $status -eq 0 ]]; then
TOPDIR=$("$GIT_TOOL" rev-parse --show-toplevel)
fi
#
CHKENTRY_TOOL=$(type -P chkentry)
export CHKENTRY_TOOL
if [[ -z "$CHKENTRY_TOOL" ]]; then
echo "$0: FATAL: chkentry tool is not installed or not in \$PATH" 1>&2
echo "$0: Notice: if needed: $GIT_TOOL clone $MKIOCCCENTRY_REPO; cd mkiocccentry" 1>&2
echo "$0: Notice: then if needed: make clobber all install" 1>&2
exit 5
fi
#
VERGE=$(type -P verge)
export VERGE
if [[ -z $VERGE ]]; then
@@ -163,6 +154,25 @@ if ! "$VERGE" "$JSTRDECODE_VERSION" "$MIN_JSTRDECODE_VERSION"; then
exit 5
fi
#
CHKENTRY_TOOL=$(type -P chkentry)
export CHKENTRY_TOOL
if [[ -z "$CHKENTRY_TOOL" ]]; then
echo "$0: FATAL: chkentry tool is not installed or not in \$PATH" 1>&2
echo "$0: Notice: if needed: $GIT_TOOL clone $MKIOCCCENTRY_REPO; cd mkiocccentry" 1>&2
echo "$0: Notice: then if needed: make clobber all install" 1>&2
exit 5
fi
export MIN_CHKENTRY_VERSION="1.1.5"
CHKENTRY_VERSION=$("$CHKENTRY" -V | head -1 | awk '{print $3;}')
if ! "$VERGE" "$CHKENTRY_VERSION" "$MIN_CHKENTRY_VERSION"; then
echo "$0: FATAL: chkentry version: $CHKENTRY_VERSION < minimum version: $MIN_CHKENTRY_VERSION" 1>&2
echo "$0: notice: consider updating chkentry from mkiocccentry repo" 1>&2
echo "$0: notice: run: git clone https://github.com/ioccc-src/mkiocccentry.git" 1>&2
echo "$0: notice: then: cd mkiocccentry && make clobber all" 1>&2
echo "$0: notice: then: cd jparse && sudo make install clobber" 1>&2
exit 5
fi
#
GTAR_TOOL=$(type -P gtar)
export GTAR_TOOL
if [[ -z "$GIT_TOOL" ]]; then