File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed
Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change 2727THIS_DIR=$( cd -P " $( dirname " $( readlink " ${BASH_SOURCE[0]} " || echo " ${BASH_SOURCE[0]} " ) " ) " && pwd)
2828TEMP_DIR=$( mktemp -d /tmp/react-native-codegen-XXXXXXXX)
2929RN_DIR=$( cd " $THIS_DIR /.." && pwd)
30- YARN_BINARY=" ${YARN_BINARY:- $(command -v yarn)} "
30+ YARN_BINARY=" ${YARN_BINARY:- $(command -v yarn || true )} "
3131USE_FABRIC=" ${USE_FABRIC:- 0} "
3232
3333cleanup () {
@@ -55,6 +55,11 @@ main() {
5555
5656 CODEGEN_REPO_PATH=" $RN_DIR /packages/react-native-codegen"
5757 CODEGEN_NPM_PATH=" $RN_DIR /../react-native-codegen"
58+
59+ if [ -z " $YARN_BINARY " ]; then
60+ echo " Error: Could not find yarn. Make sure it is in bash PATH or set the YARN_BINARY environment variable." 1>&2
61+ exit 1
62+ fi
5863
5964 if [ -d " $CODEGEN_REPO_PATH " ]; then
6065 CODEGEN_PATH=$( cd " $CODEGEN_REPO_PATH " && pwd)
You can’t perform that action at this time.
0 commit comments