Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Android studio custom gradle launch command

I would like the APK installed on the device to be generated using a custom command:

./gradlew clean assemble -PdisablePreDex

But I don't want to go to command line and then use adb install name.apk. I'm using Android Studio and I want to configure the run configuration to run with this command?

like image 567
JY2k Avatar asked Jan 18 '26 02:01

JY2k


1 Answers

  1. Click on the dropdown list to the left of the "Run" button.
  2. Click on "Edit configurations..."
  3. Click on "Gradle" then on the "+" button.
  4. Configure your custom "Run" script

screenshot

like image 103
mithrop Avatar answered Jan 19 '26 16:01

mithrop



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!