2017-11-16 20:46:06 +00:00
|
|
|
def getVersion() {
|
|
|
|
// Dynamically read version from CMake file
|
|
|
|
String text = new File('../../appInfo.cmake').getText('UTF-8')
|
|
|
|
String major = (text =~ /appVersionMajor\s+(\d+)/)[0][1]
|
|
|
|
String minor = (text =~ /appVersionMinor\s+(\d+)/)[0][1]
|
|
|
|
String patch = (text =~ /appVersionPatch\s+(\d+)/)[0][1]
|
|
|
|
String suffix = (text =~ /appVersionSuffix\s+"(.*?)"/)[0][1]
|
|
|
|
String result = "${major}.${minor}.${patch}${suffix}"
|
|
|
|
return result
|
|
|
|
}
|
|
|
|
|
2017-11-14 19:41:42 +00:00
|
|
|
group 'com.rhubarb_lip_sync'
|
2017-11-16 20:46:06 +00:00
|
|
|
version = getVersion()
|
2017-11-14 19:41:42 +00:00
|
|
|
|
|
|
|
buildscript {
|
|
|
|
ext.kotlin_version = '1.1.4-3'
|
|
|
|
|
|
|
|
repositories {
|
|
|
|
mavenCentral()
|
|
|
|
}
|
|
|
|
dependencies {
|
|
|
|
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
apply plugin: 'kotlin'
|
|
|
|
|
|
|
|
repositories {
|
|
|
|
mavenCentral()
|
|
|
|
}
|
|
|
|
|
|
|
|
dependencies {
|
|
|
|
compile "org.jetbrains.kotlin:kotlin-stdlib-jre8:$kotlin_version"
|
|
|
|
}
|
|
|
|
|
|
|
|
compileKotlin {
|
|
|
|
kotlinOptions.jvmTarget = "1.8"
|
|
|
|
}
|
|
|
|
compileTestKotlin {
|
|
|
|
kotlinOptions.jvmTarget = "1.8"
|
|
|
|
}
|