mirror of
https://github.com/gradle/actions.git
synced 2026-01-25 17:26:10 +08:00
Replace static config methods with config types
This will allow different entry points to have different inputs.
This commit is contained in:
@@ -2,7 +2,7 @@ import * as core from '@actions/core'
|
||||
import * as setupGradle from '../setup-gradle'
|
||||
import * as dependencyGraph from '../dependency-graph'
|
||||
|
||||
import {getDependencyGraphOption} from '../input-params'
|
||||
import {CacheConfig, DependencyGraphConfig, SummaryConfig} from '../input-params'
|
||||
import {PostActionJobFailure} from '../errors'
|
||||
|
||||
// Catch and log any unhandled exceptions. These exceptions can leak out of the uploadChunk method in
|
||||
@@ -15,9 +15,9 @@ process.on('uncaughtException', e => handleFailure(e))
|
||||
*/
|
||||
export async function run(): Promise<void> {
|
||||
try {
|
||||
if (await setupGradle.complete()) {
|
||||
if (await setupGradle.complete(new CacheConfig(), new SummaryConfig())) {
|
||||
// Only submit the dependency graphs once per job
|
||||
await dependencyGraph.complete(getDependencyGraphOption())
|
||||
await dependencyGraph.complete(new DependencyGraphConfig())
|
||||
}
|
||||
} catch (error) {
|
||||
if (error instanceof PostActionJobFailure) {
|
||||
|
||||
Reference in New Issue
Block a user