gradle-build-action/src/post.ts

17 lines
351 B
TypeScript
Raw Normal View History

import * as core from '@actions/core'
import * as cacheGradleUserHome from './cache-gradle-user-home'
2020-06-13 19:34:07 +08:00
// Invoked by GitHub Actions
2020-06-13 19:54:27 +08:00
export async function run(): Promise<void> {
if (isCacheReadOnly()) return
await cacheGradleUserHome.save()
2020-06-13 19:34:07 +08:00
}
function isCacheReadOnly(): boolean {
return core.getBooleanInput('cache-read-only')
}
2020-06-13 19:44:30 +08:00
run()