Skip to content

Commit a1ad200

Browse files
committed
Describe cache key format in readme
1 parent 3bc31aa commit a1ad200

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

README.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,11 @@ Currently, the following distributions are supported:
6464
**NOTE:** Adopt OpenJDK got moved to Eclipse Temurin and won't be updated anymore. It is highly recommended to migrate workflows from `adopt` to `temurin` to keep receiving software and security updates. See more details in the [Good-bye AdoptOpenJDK post](https://blog.adoptopenjdk.net/2021/08/goodbye-adoptopenjdk-hello-adoptium/).
6565

6666
### Caching packages dependencies
67-
The action has a built-in functionality for caching and restoring dependencies. It uses [actions/cache](https://github.com/actions/cache) under hood for caching dependencies but requires less configuration settings. Supported package managers are gradle and maven. The cache input is optional, and caching is turned off by default.
67+
The action has a built-in functionality for caching and restoring dependencies. It uses [actions/cache](https://github.com/actions/cache) under hood for caching dependencies but requires less configuration settings. Supported package managers are gradle and maven. The format of the used cache key is `setup-java-${{ platform }}-${{ packageManager }}-${{ fileHash }}`, where the hash is based on the following files:
68+
- gradle: `**/*.gradle*`, `**/gradle-wrapper.properties`
69+
- maven: `**/pom.xml`
70+
71+
The cache input is optional, and caching is turned off by default.
6872

6973
#### Caching gradle dependencies
7074
```yaml

0 commit comments

Comments
 (0)