Bump artifact version, do digest check

This commit is contained in:
Ryan Ghadimi 2025-03-12 13:47:20 +00:00
parent cc20338598
commit b81a615862
4 changed files with 22 additions and 12 deletions

View file

@ -117,7 +117,8 @@ async function run(): Promise<void> {
path:
isSingleArtifactDownload || inputs.mergeMultiple
? resolvedPath
: path.join(resolvedPath, artifact.name)
: path.join(resolvedPath, artifact.name),
expectedHash: artifact.digest
})
)
@ -126,6 +127,15 @@ async function run(): Promise<void> {
await Promise.all(chunk)
}
for (const dlPromise of downloadPromises) {
const outcome = await dlPromise
if (outcome.digestMismatch) {
core.warning(
`Artifact digest validation failed. Please verify the integrity of the artifact.`
)
}
}
core.info(`Total of ${artifacts.length} artifact(s) downloaded`)
core.setOutput(Outputs.DownloadPath, resolvedPath)
core.info('Download artifact has finished successfully')