Commit d61fcfa 1 parent a0ef72d commit d61fcfa Copy full SHA for d61fcfa
File tree 1 file changed +13
-8
lines changed
1 file changed +13
-8
lines changed Original file line number Diff line number Diff line change @@ -461,9 +461,12 @@ async function execAndSucceed(
461
461
args : string [ ] ,
462
462
options : ExecOptions = { }
463
463
) : Promise < void > {
464
- debug ( `running ${ program } with arguments: ${ JSON . stringify ( args ) } ` ) ;
465
- const exit = await _exec ( program , args , options ) ;
466
- if ( exit !== 0 ) throw new Error ( `${ program } exited with code ${ exit } ` ) ;
464
+ return await core . group ( `running ${ program } with arguments: ${ JSON . stringify ( args ) } ` , async ( ) => {
465
+ const exit = await _exec ( program , args , options ) ;
466
+ if ( exit !== 0 ) {
467
+ throw new Error ( `${ program } exited with code ${ exit } ` ) ;
468
+ }
469
+ } ) ;
467
470
}
468
471
469
472
async function toolExists ( name : string ) : Promise < boolean > {
@@ -489,11 +492,13 @@ async function execWithOutput(
489
492
program : string ,
490
493
args : string [ ]
491
494
) : Promise < string > {
492
- debug ( `running ${ program } with arguments: ${ JSON . stringify ( args ) } ` ) ;
493
- const { exitCode, stdout} = await getExecOutput ( program , args ) ;
494
- if ( exitCode !== 0 )
495
- throw new Error ( `${ program } exited with code ${ exitCode } ` ) ;
496
- return stdout ;
495
+ return await core . group ( `running ${ program } with arguments: ${ JSON . stringify ( args ) } ` , async ( ) => {
496
+ const { exitCode, stdout} = await getExecOutput ( program , args ) ;
497
+ if ( exitCode !== 0 ) {
498
+ throw new Error ( `${ program } exited with code ${ exitCode } ` ) ;
499
+ }
500
+ return stdout ;
501
+ } ) ;
497
502
}
498
503
499
504
function realpath ( path : string ) : string {
You can’t perform that action at this time.
0 commit comments