Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Compare ¶
Compare function compares two Debian-like package version
The implementation is based on http://man.he.net/man5/deb-version on https://www.debian.org/doc/debian-policy/ch-controlfields.html#s-f-Version
It uses the dpkg-1.17.25's algorithm (lib/version.c)
func CompareV ¶
CompareV function compares two Debian-like package version
The implementation is based on http://man.he.net/man5/deb-version on https://www.debian.org/doc/debian-policy/ch-controlfields.html#s-f-Version
It uses the dpkg-1.17.25's algorithm (lib/version.c)
Types ¶
type Version ¶
Version represents a Debian-like package version
func StringToVersion ¶
StringToVersion function parses a string into a Version struct which can be compared
The implementation is based on http://man.he.net/man5/deb-version on https://www.debian.org/doc/debian-policy/ch-controlfields.html#s-f-Version
It uses the dpkg-1.17.25's algorithm (lib/parsehelp.c)