versioned is a command line tool to work with version numbers. Features include
- check if version number matches the version number format
- removal of "-SNAPSHOT" suffix
- calculation of next release or development versions.
versioned is written in Python.
versioned supports semantic versions of the form 1.2.3-SNAPSHOT for now. This
format is known from maven (a popular java build tool) and is called 'mvn'. The
format option -f mvn
can be omitted as for now mvn
is the default. More formats
to come...
versioned -f mvn -c isVersion 1
true
versioned -f mvn -c isVersion foo
false
versioned -f mvn -c isSnapshot 1-SNAPSHOT
true
versioned -f mvn -c isSnapshot 1
false
versioned -f mvn -c isRelease 1-SNAPSHOT
false
versioned -f mvn -c isRelease 1
true
versioned -f mvn -c nextRelease 1.2.3-SNAPSHOT
1.2.3
versioned -f mvn -c nextSnapshot 1.2.3
1.2.4-SNAPSHOT