Merge pull request #263 from realm/sk-packager-bugfix

No longer delete before npm installing local modules
This commit is contained in:
Scott Kyle 2016-02-19 14:19:05 -08:00
commit f5a15473b9
6 changed files with 10 additions and 14 deletions

View File

@ -635,7 +635,7 @@
); );
runOnlyForDeploymentPostprocessing = 0; runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh; shellPath = /bin/sh;
shellScript = "rm -rf ../node_modules/realm\n[ -s \"${HOME}/.nvm/nvm.sh\" ] && . \"${HOME}/.nvm/nvm.sh\"\nnpm install realm"; shellScript = "[ -s \"${HOME}/.nvm/nvm.sh\" ] && . \"${HOME}/.nvm/nvm.sh\"\nnpm install realm";
}; };
F6C465131C48706400E79896 /* Bundle React Native code and images */ = { F6C465131C48706400E79896 /* Bundle React Native code and images */ = {
isa = PBXShellScriptBuildPhase; isa = PBXShellScriptBuildPhase;

View File

@ -5,7 +5,6 @@ set -e
PATH="/opt/android-sdk-linux/platform-tools:$PATH" PATH="/opt/android-sdk-linux/platform-tools:$PATH"
rm -rf node_modules/realm
npm install realm npm install realm
adb reverse tcp:8081 tcp:8081 adb reverse tcp:8081 tcp:8081

View File

@ -5,7 +5,6 @@ set -e
PATH="/opt/android-sdk-linux/platform-tools:$PATH" PATH="/opt/android-sdk-linux/platform-tools:$PATH"
rm -rf node_modules/realm
npm install realm npm install realm
adb reverse tcp:8081 tcp:8081 adb reverse tcp:8081 tcp:8081

View File

@ -68,6 +68,12 @@ unlock_device() {
cleanup cleanup
trap cleanup EXIT trap cleanup EXIT
# Use a consistent version of Node if possible.
if [ -s "${HOME}/.nvm/nvm.sh" ]; then
. "${HOME}/.nvm/nvm.sh"
nvm use 5.4.0 || true
fi
case "$TARGET" in case "$TARGET" in
"jsdoc") "jsdoc")
npm run jsdoc npm run jsdoc
@ -82,7 +88,7 @@ case "$TARGET" in
unzip -q ../../target=node_modules/react_tests_node_modules.zip unzip -q ../../target=node_modules/react_tests_node_modules.zip
fi fi
npm update react-native npm install
open_chrome open_chrome
start_packager start_packager
popd popd
@ -96,7 +102,7 @@ case "$TARGET" in
unzip -q ../../target=node_modules/react_example_node_modules.zip unzip -q ../../target=node_modules/react_example_node_modules.zip
fi fi
npm update react-native npm install
open_chrome open_chrome
start_packager start_packager
@ -108,13 +114,6 @@ case "$TARGET" in
exit 0 exit 0
fi fi
[ -s "${HOME}/.nvm/nvm.sh" ] && . "${HOME}/.nvm/nvm.sh"
nvm use 5.4.0 || true
pushd react-native/android
./gradlew installarchives
popd
pushd tests/react-test-app pushd tests/react-test-app
npm install npm install

View File

@ -615,7 +615,7 @@
); );
runOnlyForDeploymentPostprocessing = 0; runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh; shellPath = /bin/sh;
shellScript = "[ -s \"${HOME}/.nvm/nvm.sh\" ] && . \"${HOME}/.nvm/nvm.sh\" \nrm -rf ../node_modules/realm ../node_modules/realm-tests\nnpm install realm realm-tests\ncp ../../../src/object-store/parser/queryTests.json ../node_modules/realm-tests/query-tests.json\n"; shellScript = "[ -s \"${HOME}/.nvm/nvm.sh\" ] && . \"${HOME}/.nvm/nvm.sh\" \nnpm install realm realm-tests\ncp ../../../src/object-store/parser/queryTests.json ../node_modules/realm-tests/query-tests.json\n";
}; };
F6EDE5BF1C49007200B1085F /* Bundle React Native code and images */ = { F6EDE5BF1C49007200B1085F /* Bundle React Native code and images */ = {
isa = PBXShellScriptBuildPhase; isa = PBXShellScriptBuildPhase;

View File

@ -5,7 +5,6 @@ set -e
PATH="/opt/android-sdk-linux/platform-tools:$PATH" PATH="/opt/android-sdk-linux/platform-tools:$PATH"
rm -rf node_modules/realm node_modules/realm-tests
npm install realm realm-tests npm install realm realm-tests
cp ../../src/object-store/parser/queryTests.json node_modules/realm-tests/query-tests.json cp ../../src/object-store/parser/queryTests.json node_modules/realm-tests/query-tests.json