mirror of
https://github.com/gradle/gradle-build-action.git
synced 2025-10-20 07:08:56 +08:00
Use build-results file for root project dirs
Instead of using a separate mechanism and init script, reuse the information captured in the build-results file.
This commit is contained in:
@@ -3,7 +3,7 @@ import fs from 'fs'
|
||||
import path from 'path'
|
||||
import {logCachingReport, CacheListener} from './cache-reporting'
|
||||
|
||||
interface BuildResult {
|
||||
export interface BuildResult {
|
||||
get rootProjectName(): string
|
||||
get rootProjectDir(): string
|
||||
get requestedTasks(): string
|
||||
@@ -28,7 +28,7 @@ export function writeJobSummary(cacheListener: CacheListener): void {
|
||||
core.summary.write()
|
||||
}
|
||||
|
||||
function loadBuildResults(): BuildResult[] {
|
||||
export function loadBuildResults(): BuildResult[] {
|
||||
const buildResultsDir = path.resolve(process.env['RUNNER_TEMP']!, '.build-results')
|
||||
if (!fs.existsSync(buildResultsDir)) {
|
||||
return []
|
||||
|
Reference in New Issue
Block a user