Version string parsing and comparison

Author(s): Jose F. Morales.

This module contains operations to work with version strings (as atoms). The specification of the format and operations is partially inspired on Semantic Versioning.

Normal versions are specified as strings of the form X.Y.Z, where X, Y, and Z are non-negative integers. The components denote the major, minor, and patch version, respectively. Missing version numbers are assumed to be 0.

Pre-release versions include an optional pre-release identifier (X.Y.Z-Prerelease), which itself may contain many dot separated components.

Versions are compared by comparing each component from left to right. Each component is compared numerically (if numbers) or lexicographically (if not numbers). Numeric components have lower precedence than non-numeric components. A pre-release version has lower precedence than its corresponding normal version.

Usage and interface

Documentation on exports

Usage:version_split_patch(VerAtm,VerNopatchAtm,PatchAtm)

Split version VerAtm into major and minor VerNopatchAtm, and patch and prerelease PatchAtm)

    Usage:version_compare(C,A,B)

    Compare versions A and B (see compare/3 for values of C)

      Documentation on imports

      This module has the following direct dependencies: