thoughtbot / belt

Belt is a CLI for starting a new React Native Expo app and will even keep your pants secure as you continue development.
MIT License
131 stars 3 forks source link

Don't pass @latest when creating Expo app with yarn #30

Closed stevehanson closed 10 months ago

stevehanson commented 10 months ago

When starting a new thoughtbelt project with npx thoughtbelt MyApp --yarn, thoughtbelt was attempting to create the Expo app with yarn using the yarn create expo@latest MyApp command. This was failing, because yarn create does not seem to support the @latest symbol. This PR updates so we no longer pass @latest when creating the Expo app with Yarn.

The error was:

...
? Ready to proceed? yes

⠸ Creating new app with create-expo-appnode:internal/errors:867
  const err = new Error(message);
              ^

Error: Command failed: yarn create expo@latest UsaGym
warning package.json: No license field
/bin/sh: /Users/shanson/.yarn/bin/create-expo@latest: No such file or directory
error Command failed.
Exit code: 127
Command: /Users/shanson/.yarn/bin/create-expo@latest
Arguments: UsaGym
Directory: /Users/shanson/dev/thoughtbelt-playground