File tree Expand file tree Collapse file tree 1 file changed +17
-18
lines changed
packages/host/src/node/cli Expand file tree Collapse file tree 1 file changed +17
-18
lines changed Original file line number Diff line number Diff line change @@ -77,24 +77,23 @@ export const command = new Command("vendor-hermes")
7777 "ReactCommon/jsi/jsi/"
7878 ) ;
7979
80- if (
81- fs . existsSync ( reactNativeJsiPath ) &&
82- ( force ||
83- getLatestMtime ( hermesJsiPath ) > getLatestMtime ( reactNativeJsiPath ) )
84- ) {
85- await oraPromise (
86- fs . promises . cp ( hermesJsiPath , reactNativeJsiPath , {
87- recursive : true ,
88- } ) ,
89- {
90- text : `Copying JSI from Hermes to React Native` ,
91- successText : "Copied JSI from Hermes to React Native" ,
92- failText : ( err ) =>
93- `Failed to copy JSI from Hermes to React Native: ${ err . message } ` ,
94- isEnabled : ! silent ,
95- }
96- ) ;
97- }
80+ assert (
81+ fs . existsSync ( hermesJsiPath ) ,
82+ `Hermes JSI path does not exist: ${ hermesJsiPath } `
83+ ) ;
84+
85+ await oraPromise (
86+ fs . promises . cp ( hermesJsiPath , reactNativeJsiPath , {
87+ recursive : true ,
88+ } ) ,
89+ {
90+ text : `Copying JSI from patched Hermes to React Native` ,
91+ successText : "Copied JSI from patched Hermes to React Native" ,
92+ failText : ( err ) =>
93+ `Failed to copy JSI from Hermes to React Native: ${ err . message } ` ,
94+ isEnabled : ! silent ,
95+ }
96+ ) ;
9897 console . log ( hermesPath ) ;
9998 } catch ( error ) {
10099 if ( error instanceof SpawnFailure ) {
You can’t perform that action at this time.
0 commit comments