![]() ![]() To test if your development environment works, run: npx react-native init AwesomeProject cd AwesomeProject npx react-native run-androidĪnd it should work fine. In a later development, having the command line tools available will make everything easier, so similar to what we did to the ANDROID_HOME environment variable, we add the following lines to the $HOME/.bash_profile or $HOME/.bashrc (if you are using zsh then ~/.zprofile or ~/.zshrc) config file: export PATH="$"Īgain, make sure to restart the bash. So, instead of selecting these packages from the Android Studio SDK Manager, we will install it using the command line with the following command: $ANDROID_HOME/cmdline-tools/tools/bin/sdkmanager "platform-tools" "platforms android-29" "build-tools 29.0.2" "add-ons addon-google_apis-google-24"Ī very useful link is this gist, which keeps track of all the available packages, its description, and its versions. The SDK platforms are the Android platforms you can develop. You’ll be greeted with a list of files under the tabs SDK Platforms and SDK Tools. Intel x86 Atom_64 System Image or Google APIs Intel x86 Atom System Image Open the manager by heading to Tools > SDK Manager.The official React Native environment setup recommends installing the following SDK packages: Make sure you restart the bash to apply the changes.Īlso, make sure you have writing permissions to the android home folder: sudo chown -R $(whoami) $ANDROID_HOME 5. Instead of only exporting the ANDROID_HOME to the current session of the terminal, we make sure that it’s permanently added to the terminal by adding the following lines to your $HOME/.bash_profile or $HOME/.bashrc (if you are using zsh then ~/.zprofile or ~/.zshrc) config file: export ANDROID_HOME=/opt/android ![]() Select the device on which you want to run the application and then click OK. ![]() The React Native tools require some environment variables to be set up to build apps with native code. Android Studio displays the connected devices and available emulators. Open Android studio app from applications now. Export the ANDROID_HOME environment variable Download and install Android studio : Drag above android studio to applications. ![]()
0 Comments
Leave a Reply. |