mirror of https://github.com/sbt/sbt.git
592 B
592 B
cacheVersion setting
sbt 2.x caches task results by default. cacheVersion provides an escape hatch to invalidate all caches when needed.
Usage
In build.sbt:
Global / cacheVersion := 1L
Or via system property:
sbt -Dsbt.cacheversion=1
Details
- Defaults to reading system property
sbt.cacheversion, or else0L - When
cacheVersionis0L, caching behaves identically to previous versions - Changing the value invalidates all task caches, forcing recomputation
- The value is incorporated into every cache key via
BuildWideCacheConfiguration