mirror of
https://github.com/actions/setup-java.git
synced 2025-09-30 04:45:48 +00:00
Add caching for the Mill build tool
This commit is contained in:
parent
f4f1212c88
commit
18d114c65a
9 changed files with 214 additions and 7 deletions
17
src/cache.ts
17
src/cache.ts
|
@ -13,7 +13,7 @@ const CACHE_MATCHED_KEY = 'cache-matched-key';
|
|||
const CACHE_KEY_PREFIX = 'setup-java';
|
||||
|
||||
interface PackageManager {
|
||||
id: 'maven' | 'gradle' | 'sbt';
|
||||
id: 'maven' | 'gradle' | 'sbt' | 'mill';
|
||||
/**
|
||||
* Paths of the file that specify the files to cache.
|
||||
*/
|
||||
|
@ -60,6 +60,21 @@ const supportedPackageManager: PackageManager[] = [
|
|||
'**/project/**.scala',
|
||||
'**/project/**.sbt'
|
||||
]
|
||||
},
|
||||
{
|
||||
id: 'mill',
|
||||
path: [
|
||||
join(os.homedir(), '.cache', 'mill')
|
||||
],
|
||||
pattern: [
|
||||
// https://github.com/coursier/cache-action/blob/4e2615869d13561d626ed48655e1a39e5b192b3c/README.md?plain=1#L28-L38
|
||||
'**/build.sc',
|
||||
'**/*.sc',
|
||||
'**/mill',
|
||||
'**/.mill-version',
|
||||
// https://github.com/com-lihaoyi/mill/blob/5b88d1e268e6264e44589c5ac82c0fdbd680fd63/mill#L6-L11
|
||||
'**/.config/mill-version'
|
||||
]
|
||||
}
|
||||
];
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue