Add an option to specify retention period

This commit is contained in:
Yang Cao 2020-08-27 13:39:36 -04:00
parent 58740802ef
commit 59018c2f85
8 changed files with 66 additions and 10 deletions

View file

@ -22,9 +22,16 @@ export function getInputs(): UploadInputs {
)
}
return {
const inputs = {
artifactName: name,
searchPath: path,
ifNoFilesFound: noFileBehavior
} as UploadInputs
const retentionDaysStr = core.getInput(Inputs.RetentionDays)
if (retentionDaysStr) {
inputs.retentionDays = parseInt(retentionDaysStr)
}
return inputs
}