revvercmp - comparison of version numbers
version-lt - prints the lower version
#include "verrevcmp.h"
int verrevcmp(const char *val, const char *ref);
version-lt [OPTIONS] VERS VERS_REF
Prints the Lower version of VERS and VERS_REF.
echo "$VERS" "$VERS_REF" | verrevcmp.awk
version-lt.sh [OPTIONS] VERS VERS_REF
Prints the Lower version of VERS and VERS_REF.
-e or --equal Lower or Equal.
-q or --quiet Quiet.
-D or --debug Turn on debug traces.
-h or --help Display this message.
-V or --version Display the version.
Exits success if VERS is Lower Than (lt) VERS_REF.
It comes in two versions.
The C version uses verrecmp function extracted from the Debian packaging suite library routines. This version serves as reference behavior.
The shell version uses a rewritten version of the C function **int verrevcmp(const char val, const char ref); in awk.
See Makefile.
Written by Gaël PORTAY gael.portay@gmail.com
Copyright (c) 1995 Ian Jackson iwj10@cus.cam.ac.uk
Copyright (c) 2016-2017 Gaël PORTAY
This program is free software: you can redistribute it and/or modify it under the terms of the MIT License.