Added proper gradle release build.
This commit is contained in:
parent
c9b078cf62
commit
80a8387090
3 changed files with 41 additions and 1 deletions
|
@ -61,6 +61,8 @@
|
||||||
</content>
|
</content>
|
||||||
<orderEntry type="jdk" jdkName="Android API 19 Platform" jdkType="Android SDK" />
|
<orderEntry type="jdk" jdkName="Android API 19 Platform" jdkType="Android SDK" />
|
||||||
<orderEntry type="sourceFolder" forTests="false" />
|
<orderEntry type="sourceFolder" forTests="false" />
|
||||||
|
<orderEntry type="library" exported="" name="appcompat-v7-19.1.0" level="project" />
|
||||||
|
<orderEntry type="library" exported="" name="support-v4-19.1.0" level="project" />
|
||||||
<orderEntry type="module" module-name="libsuperuser" exported="" />
|
<orderEntry type="module" module-name="libsuperuser" exported="" />
|
||||||
</component>
|
</component>
|
||||||
</module>
|
</module>
|
||||||
|
|
|
@ -1,4 +1,26 @@
|
||||||
|
buildscript {
|
||||||
|
repositories {
|
||||||
|
mavenCentral()
|
||||||
|
}
|
||||||
|
|
||||||
|
dependencies {
|
||||||
|
classpath 'com.alexvasilkov:android_sign:0.2+'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
import java.util.regex.Pattern
|
||||||
|
|
||||||
apply plugin: 'com.android.application'
|
apply plugin: 'com.android.application'
|
||||||
|
apply plugin: 'android_sign'
|
||||||
|
|
||||||
|
repositories {
|
||||||
|
mavenCentral()
|
||||||
|
}
|
||||||
|
|
||||||
|
dependencies {
|
||||||
|
compile 'com.android.support:appcompat-v7:19.1.+'
|
||||||
|
}
|
||||||
|
|
||||||
android {
|
android {
|
||||||
compileSdkVersion 19
|
compileSdkVersion 19
|
||||||
buildToolsVersion '19.1.0'
|
buildToolsVersion '19.1.0'
|
||||||
|
@ -14,11 +36,27 @@ android {
|
||||||
testFunctionalTest true
|
testFunctionalTest true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
signingConfigs {
|
||||||
|
release {
|
||||||
|
// Android Studio does not pass environment variables.
|
||||||
|
// This means you have to use the command line for release builds.
|
||||||
|
def ks = System.getenv("KEYSTORE")
|
||||||
|
def ka = System.getenv("KEY_ALIAS")
|
||||||
|
if (ks != null && ka != null) {
|
||||||
|
storeFile file(ks)
|
||||||
|
keyAlias ka
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
buildTypes {
|
buildTypes {
|
||||||
debug {
|
debug {
|
||||||
applicationIdSuffix ".debug"
|
applicationIdSuffix ".debug"
|
||||||
debuggable true
|
debuggable true
|
||||||
}
|
}
|
||||||
|
release {
|
||||||
|
signingConfig signingConfigs.release
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Reference in a new issue