Bläddra i källkod

fixing install script

Daniel Zlotin 7 år sedan
förälder
incheckning
da7fe3a584
3 ändrade filer med 6 tillägg och 6 borttagningar
  1. 2
    2
      playground/package.json
  2. 4
    2
      playground/scripts/postinstall.js
  3. 0
    2
      scripts/test.ios.js

+ 2
- 2
playground/package.json Visa fil

@@ -11,9 +11,9 @@
11 11
   },
12 12
   "dependencies": {
13 13
     "react-native": "0.38.0",
14
-    "react": "15.4.1",
15
-    "react-native-navigation": "file:../"
14
+    "react": "15.4.1"
16 15
   },
16
+  "//": "use react-native-navigation: 2.x.x --> we are manually installing it from a script for quicker workflow",
17 17
   "devDependencies": {
18 18
     "detox": "4.x.x",
19 19
     "detox-server": "1.x.x",

+ 4
- 2
playground/scripts/postinstall.js Visa fil

@@ -2,5 +2,7 @@ const shellUtils = require('shell-utils');
2 2
 
3 3
 shellUtils.exec.execSync(`rm yarn.lock || true`);
4 4
 shellUtils.exec.execSync(`./scripts/ignoreReactWarnings.rb`);
5
-shellUtils.exec.execSync(`rm -rf node_modules/react-native-navigation/node_modules`);
6
-shellUtils.exec.execSync(`rm -rf node_modules/react-native-navigation/playground`);
5
+
6
+shellUtils.exec.execSync(`mkdir -p ./node_modules/react-native-navigation`);
7
+shellUtils.exec.execSync(`cd .. && npm pack`);
8
+//shellUtils.exec.execSync(`tar -xf ../react-native-navigation.tar`);

+ 0
- 2
scripts/test.ios.js Visa fil

@@ -3,8 +3,6 @@ const exec = require('shell-utils').exec;
3 3
 function run() {
4 4
   process.chdir('./playground');
5 5
   exec.execSync(`hardlink node_modules/react-native-navigation/ -u || true`);
6
-  const yarnCacheDir = exec.execSyncRead(`yarn cache dir`);
7
-  exec.execSync(`rm -rf ${yarnCacheDir}/*navigation*`);
8 6
   exec.execSync(`yarn install`);
9 7
   exec.execSync(`yarn run e2e release`);
10 8
   process.chdir('../');