forked from crnk-project/crnk-framework
-
Notifications
You must be signed in to change notification settings - Fork 0
/
versions.gradle
22 lines (19 loc) · 845 Bytes
/
versions.gradle
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
// handles loading of version properties
// NOTE: needs to happen in buildscript section before setting up the gralde classpath
// load global properties
Properties versionsProperties = new Properties()
def versionsFile = project.file("versions.properties")
versionsFile.withInputStream { versionsProperties.load(it) }
// load local overrides for development:
// introduce 0.0.0.0-SNAPSHOT dependencies in a multi-project setup to
// ensure local artifact usage. Gives full control of those dependencies
// and updates compared to artifacts built and fetched from remote build
// servers/repositories.
def localFile = project.file("local.properties")
if (localFile.exists()) {
localFile.withInputStream { versionsProperties.load(it) }
}
// make properties available in build.gradle
allprojects {
project.ext.versions = versionsProperties
}