0

Often I'm making some small changes, within one file, not touching 99% of the code. For example: small refactoring, tweaking parameters, layouts, animations. Changes which take couple of seconds. I just want to quickly experiment with many options and see what is the best.

There is a huge problem - recompilation and deploying time. I waste my time and lose my focus, which dramatically increases total tweaking time - from seconds of actual work to minutes (hours?), because of waiting and constant distractions. It's also annoying and doesn't encourage to experiment more.

I've heard about DyCI - Dynamic Code Injection, which does exactly what I want - "change your code and see the results right away". But, it's for iOS.

Is it possible to change the code and see the results right away on Android? How?

Adam Stelmaszczyk
  • 19,665
  • 4
  • 70
  • 110

2 Answers2

1

You could use incremental dex-ing

Full Incremental Builds – The new Gradle-based Android build system has been designed for developer efficiency. Gradle’s support for incremental tasks means you spend less time waiting and more time coding.

from https://www.gradleware.com/android/gradle-the-new-android-build-system/

Also What does the "Incremental Dex" option in Android Studio do?

Community
  • 1
  • 1
harrane
  • 959
  • 11
  • 24
0

If you're talking about hotswap, I think it's not possible with Dalvik VM (android's java virtual machine). This answer tells it too

Community
  • 1
  • 1
Javi Mollá
  • 786
  • 7
  • 18