Skip to content

Fall back to Gradle compilation

Jugg tries incremental compilation first by default. When the current changes need verification through the complete Gradle pipeline, or when you want to refresh the full-build baseline, you can make the current run use Gradle compilation. It is slower, but the result is closer to a native Android Studio Run.

Run when no files have changed

When you click Jugg Run again without any newly saved changes, Jugg may ask whether to continue with Gradle compilation.

ChoiceResult
YesUse Gradle compilation for this run, then install and launch the app
NoCancel this run
Clean And ReinstallClear app data and reinstall the APK
Export incremental APKExport the incremental APK that has already been compiled

This usually means either that you intentionally want to refresh the baseline or that you clicked Run by mistake. Select No if it was accidental.

Use the fallback button

When you know you need a full Gradle build, click (Jugg) Fallback to Gradle Compile in the IDE. From a terminal or an agent, run:

bash
jugg gradle-build

Use an explicit fallback when:

  • You just switched branches or pulled many changes.
  • You changed the Gradle plugin, dependencies, source sets, or Manifest placeholders.
  • You suspect the incremental result is incorrect and need a Gradle comparison.
  • You deleted a class, resource, or Manifest node and need to confirm that the old content is gone.

After Gradle succeeds, Jugg reloads the APK, classpath, mapping, and resource baseline. Subsequent small changes can still use Jugg Run.

The build-file change dialog

After you modify build.gradle, settings.gradle, or dependency declarations, Jugg may display a dependency-change dialog. If the same run also contains too many source changes, Jugg first asks whether to continue the large incremental compilation. The build-file changes appear only after you select Continue Incremental Compile.

ChoiceWhen to choose it
Fallback to GradleYou are unsure how the dependency change affects the build, or you changed a plugin, variant, or source set
Find out changed LibrariesYou changed only a library version and want Jugg to try incremental compilation for the changed library
Ignore build changesYou know the build-file change is unrelated to the current APK
Close the dialogCancel this run

When in doubt, choose Fallback to Gradle. Spending more time here is usually easier than continuing with an inaccurate baseline.

The too-many-changes dialog

When one change covers too many source files or modules, or when the current change requires compiling too many additional affected files, Jugg may show a confirmation dialog. Incremental compilation of that set is usually slower than a full Gradle build, so Gradle remains the default.

ChoiceResult
Fallback to GradleUse a full build for this run. The button is available immediately
Continue Incremental CompileKeep incremental compilation for this run only. The button waits for a 2-second countdown
Close the dialogCancel this run

MCP, CLI, and status queries do not show this dialog and fall back to Gradle directly.