File tree Expand file tree Collapse file tree 3 files changed +20
-20
lines changed
platform-android/src/lib/commands/runAndroid
platform-apple-helpers/src/lib/commands/run Expand file tree Collapse file tree 3 files changed +20
-20
lines changed Original file line number Diff line number Diff line change 1+ ---
2+ ' @rnef/platform-apple-helpers ' : patch
3+ ' @rnef/platform-android ' : patch
4+ ---
5+
6+ feat: continue with local build instead of prompting
Original file line number Diff line number Diff line change @@ -13,7 +13,6 @@ import {
1313 isInteractive ,
1414 logger ,
1515 outro ,
16- promptConfirm ,
1716 promptSelect ,
1817 RnefError ,
1918} from '@rnef/tools' ;
@@ -86,15 +85,14 @@ export async function runAndroid(
8685 binaryPath = cachedBuild . binaryPath ;
8786 }
8887 } catch ( error ) {
89- logger . warn ( ( error as RnefError ) . message ) ;
90- const shouldContinueWithLocalBuild = await promptConfirm ( {
91- message : 'Would you like to continue with local build?' ,
92- confirmLabel : 'Yes' ,
93- cancelLabel : 'No' ,
94- } ) ;
95- if ( ! shouldContinueWithLocalBuild ) {
96- throw new RnefError ( 'Cancelled run' ) ;
97- }
88+ const message = ( error as RnefError ) . message ;
89+ const cause = ( error as RnefError ) . cause ;
90+ logger . warn (
91+ `Failed to fetch cached build for ${ artifactName } : \n${ message } ` ,
92+ cause ? `\nCause: ${ cause . toString ( ) } ` : ''
93+ ) ;
94+ logger . debug ( 'Remote cache failure error:' , error ) ;
95+ logger . info ( 'Continuing with local build' ) ;
9896 }
9997 }
10098
Original file line number Diff line number Diff line change 88 getLocalBuildCacheBinaryPath ,
99 isInteractive ,
1010 logger ,
11- promptConfirm ,
1211 promptSelect ,
1312 RnefError ,
1413 saveLocalBuildCache ,
@@ -82,15 +81,12 @@ export const createRun = async ({
8281 } catch ( error ) {
8382 const message = ( error as RnefError ) . message ;
8483 const cause = ( error as RnefError ) . cause ;
85- logger . warn ( message , cause ? `\nCause: ${ cause . toString ( ) } ` : '' ) ;
86- const shouldContinueWithLocalBuild = await promptConfirm ( {
87- message : 'Would you like to continue with local build?' ,
88- confirmLabel : 'Yes' ,
89- cancelLabel : 'No' ,
90- } ) ;
91- if ( ! shouldContinueWithLocalBuild ) {
92- throw new RnefError ( 'Cancelled run' ) ;
93- }
84+ logger . warn (
85+ `Failed to fetch cached build for ${ artifactName } : \n${ message } ` ,
86+ cause ? `\nCause: ${ cause . toString ( ) } ` : ''
87+ ) ;
88+ logger . debug ( 'Remote cache failure error:' , error ) ;
89+ logger . info ( 'Continuing with local build' ) ;
9490 }
9591 }
9692
You can’t perform that action at this time.
0 commit comments