Gradle: Output the computed version name and code to text files for further processing.

This commit is contained in:
Henrik Rydgård 2017-03-27 16:58:08 +02:00
parent 9f3580f67d
commit 60f74c3ba2
2 changed files with 5 additions and 0 deletions

2
.gitignore vendored
View File

@ -53,6 +53,8 @@ PPSSPPControls.dat
*.iml
build
build.ios
versionname.txt
versioncode.txt
build*/

View File

@ -46,6 +46,9 @@ android {
println "(not using these:) Android Version Name, Code: " + androidGitVersion.name() + " " + androidGitVersion.code();
}
new File("versionname.txt").write(androidGitVersion.name())
new File("versioncode.txt").write(androidGitVersion.code().toString())
minSdkVersion 9
targetSdkVersion 25
if (project.hasProperty("ANDROID_VERSION_CODE") && project.hasProperty("ANDROID_VERSION_NAME")) {