Convert a version string to the semantic versioning format

semver

semver --coerce {{1.2}}

click the source code to copy install semver on any operating system with command-not-found.com