Merge pull request #754 from vjeux/warn_global_cli

Warn when installing globally react-native instead of react-native-cli
This commit is contained in:
Christopher Chedeau 2015-04-08 11:29:50 -07:00
commit d2c00d58c5
2 changed files with 8 additions and 0 deletions

View File

@ -0,0 +1,7 @@
#!/usr/bin/env node
console.error([
'\033[31mLooks like you installed react-native globally, maybe you meant react-native-cli?',
'To fix the issue, run:\033[0m',
'npm uninstall -g react-native',
'npm install -g react-native-cli'
].join('\n'));

View File

@ -39,6 +39,7 @@
"start": "./packager/packager.sh"
},
"bin": {
"react-native": "local-cli/wrong-react-native.js",
"react-native-start": "packager/packager.sh"
},
"dependencies": {