2

I am working on hybrid application for that every time i have to move some files from some place to assets in android application,so for this i wrote batch file.If i execute line by line command in command prompt it is working but if run batch file it is stopping before installing apk in device.

commands:

D:
cd D:\NewFolder\SampleApp
gradlew.bat assembleDebug
cd D:\NewFolder\SampleApp\app\build\outputs\apk
adb -d install  app-debug.apk
skyshine
  • 2,767
  • 7
  • 44
  • 84

1 Answers1

0

If we are running in multiple batch files in batch file,we should use call for gradlew.bat assembleDebug, Actually it is closing command prompt so that remaining commands are not executing.

commands:

D:
cd D:\NewFolder\SampleApp
call gradlew.bat assembleDebug
cd D:\NewFolder\SampleApp\app\build\outputs\apk
adb -d install  app-debug.apk
skyshine
  • 2,767
  • 7
  • 44
  • 84