File tree Expand file tree Collapse file tree 2 files changed +17
-1
lines changed
Expand file tree Collapse file tree 2 files changed +17
-1
lines changed Original file line number Diff line number Diff line change 55 "main" : " lib/index.js" ,
66 "scripts" : {
77 "start" : " npm run start-sample --" ,
8- "start-sample" : " react-native start --root samples/SampleApp" ,
8+ "start-sample" : " node rn-wrapper.js start --projectRoots samples/SampleApp,. " ,
99 "run-sample-android" : " react-native run-android --root samples/SampleApp" ,
1010 "run-sample-ios" : " react-native run-ios --project-path samples/SampleApp/ios"
1111 },
Original file line number Diff line number Diff line change 1+
2+ const path = require ( 'path' )
3+
4+ // modify paths to be absolute
5+ const PATH_ARG_RE = / ^ - - ? ( r o o t | p r o j e c t R o o t s ) $ /
6+ const argv = process . argv
7+ for ( let i = 2 ; i < argv . length ; ++ i ) {
8+ if ( PATH_ARG_RE . test ( argv [ i - 1 ] ) ) {
9+ argv [ i ] = argv [ i ] . split ( ',' ) . map ( function ( p ) {
10+ return path . resolve ( __dirname , p )
11+ } ) . join ( ',' )
12+ }
13+ }
14+
15+ const cli = require ( 'react-native/cli' )
16+ cli . run ( )
You can’t perform that action at this time.
0 commit comments