//! `gradle.properties` emitter — configures Gradle toolchain behavior.
//!
//! Emits `gradle.properties` to allow Gradle to auto-detect the host JDK.
//! The Foojay toolchain resolver plugin (configured in settings.gradle.kts)
//! handles automatic JDK downloads when needed.

/// Emit `gradle.properties` with toolchain settings.
pub fn emit() -> String {
    r#"# Generated by alef. Do not edit by hand.

# Allow Gradle to auto-detect JDK installations on the build machine.
# The Foojay resolver plugin in settings.gradle.kts provides automatic
# JDK download capability when a requested version is not found locally.
org.gradle.java.installations.auto-detect=true

# Increase heap for large multi-project builds.
org.gradle.jvmargs=-Xmx4g
"#
    .to_string()
}
