qitoolchain.version – Managing packages versions

Set of tools relate to version numbers

qitoolchain.version.compare

qitoolchain.version.compare(a_str, b_str)

Compare two versions

>>> compare("1.2.3", "1.2.3")
0
>>> compare("1.2.3", "1.2.3-rc1")
-1
>>> compare("1.20", "1.3")
1
>>> compare("1.20", "1.3-rc2")
1