I want to build my gradle project with a certain buildtype and deploy it on device with a single command.
My build.gradle is setup for multiple buildtypes such as live and release.
I worked with maven before and i look for an equivalent of:
mvn clean install -P release android:deploy android:run
Here is the command to build and deploy through a specified BuildType. ( Thank you Varun! )
gradle installProfilename
Where Profilename of course would be the name of the BuildType specified in build.gradle
Example.:
gradle installRelease
Would build with the release profile:
buildTypes {
    release {
        debuggable false
        jniDebugBuild false
        signingConfig signingConfigs.main
        . . . 
    }
Addition.:
Gradle can show you what tasks are available.:
gradle tasks
                        If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With