File tree Expand file tree Collapse file tree 2 files changed +6
-1
lines changed Expand file tree Collapse file tree 2 files changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -92,6 +92,10 @@ inputs:
9292 description : Use system provided `unzip` utility instead of JS library for unpacking
9393 required : false
9494 default : false
95+ merge_multiple :
96+ description : If multiple artifacts are found with `name_is_regexp` set to `true`, merge them into one directory
97+ required : false
98+ default : false
9599outputs :
96100 error_message :
97101 description : The error message, if an error occurs
Original file line number Diff line number Diff line change @@ -39,6 +39,7 @@ async function main() {
3939 const skipUnpack = core . getBooleanInput ( "skip_unpack" )
4040 const ifNoArtifactFound = core . getInput ( "if_no_artifact_found" )
4141 const useUnzip = core . getBooleanInput ( "use_unzip" )
42+ const mergeMultiple = core . getBooleanInput ( "merge_multiple" )
4243 let workflow = core . getInput ( "workflow" )
4344 let workflowSearch = core . getBooleanInput ( "workflow_search" )
4445 let workflowConclusion = core . getInput ( "workflow_conclusion" )
@@ -268,7 +269,7 @@ async function main() {
268269 continue
269270 }
270271
271- const dir = name && ! nameIsRegExp ? path : pathname . join ( path , artifact . name )
272+ const dir = name && ( ! nameIsRegExp || mergeMultiple ) ? path : pathname . join ( path , artifact . name )
272273
273274 fs . mkdirSync ( dir , { recursive : true } )
274275
You can’t perform that action at this time.
0 commit comments