Using the Gradle Plug-in
Customizing Buildless integration with Gradle
Our Gradle plugin is the easiest way to use Buildless with Gradle. We update the plug-in regularly, and it is designed to be minimally invasive to your builds.
Plug-in Configuration Options
The plug-in is designed to work out of the box with no additional config options. You can add any of the below options to customize the plug-in's default behavior:
| Option | Default value | Description | 
|---|---|---|
| debug | false | Activates debug logging and API tracing | 
| telemetry | true | Controls build telemetry | 
| reportErrors | true | Governs whether errors are reported back to Buildless | 
| localCache.enabled | true | Whether to enable Gradle's local (on-disk) build cache | 
| localCache.directory | (None) | Directory where local caches should be stored (see docs) | 
| remoteCache.enabled | true | Whether to enable the Buildless remote cache service | 
| remoteCache.endpoint | (Buildless) | Override cache endpoint for enterprise tenant | 
Reference Docs
The API reference docs show all available configuration options, and additionally document the entirety of the plug-in's public surface.
Complete config example
import build.less.plugin.settings.buildless
plugins {
  id("build.less") version "..."
}
buildless {
  // various flags:
  debug = true  // activate or deactivate debug mode (verbose logging, API tracing, etc)
  telemetry = true  // activate or deactivate private build telemetry (build analytics in the dashboard)
  reportErrors = true  // activate or deactivate error reporting to the buildless team (just plugin errors)
  // options for configuring your API key:
  apiKey("...")
  apiKey(ApiKey.of("..."))
  apiKey(ApiKey.of("...", type = SubjectType.ORG))
  // configuring local caching (it defaults to being active):
  localCache.enabled = true  // turn the local cache on or off
  localCache.directory = "..."  // set the directory where the cache is stored (defaults to .gradle/cache)
  // or...
  localCache {
    enabled = true
    directory = "..."
  }
  // configuring remote caching (it defaults to being active):
  remoteCache.enabled = true  // turn the remote cache on or off
  remoteCache.endpoint = "..."  // set a custom or enterprise cache endpoint (not usually necessary)
  // or...
  remoteCache {
    enabled = true
    endpoint = "..."
  }
}
Updated almost 2 years ago
