Versioning - maxirosson/jdroid-gradle-plugin GitHub Wiki

The plugin will automatically force the project version to follow the Semantic Versioning guidelines.

In order to configure the version, you need to define it before the plugin apply. If you don't assign a version, 0.1.0 will be assigned by default and a warning will be displayed. The root project version is used if you don't define a version on a subproject.

The following example will generate project version 1.2.3-SNAPSHOT or 1.2.3 if your run your gradle commands with -PSNAPSHOT=false

version = '1.2.3'
apply plugin: 'com.jdroid.XXXX'

Environment Configuration

VERSION_CLASSIFIER

The version classifier. Optional String. The default value is 'SNAPSHOT' if the SNAPSHOT property is true

SNAPSHOT

Whether the version classifier should be SNAPSHOT or not. Required Boolean. The default value is true

LOCAL

Whether the version classifier should include LOCAL or not. Required Boolean. The default value is false

VERSION_TIMESTAMP_ENABLED

Whether the version classifier should include a timestamp or not. Required Boolean. The default value is false

Tasks

Increment Version Tasks

Print Version Task