I am trying to start an Android emulator command line that works fine, but it never goes to the npx react-native run-android line from the script after it is loaded. Is there something I need to do?
emulator -list-avds
# Ask the user if they want to run the app on the simulator
read -p "Which Android emulator name (i.e. Pixel_7_Pro_API_34)?: " device
emulator -avd $device
npx react-native run-android
One option might be to launch the selected emulator in background, wait for it to start and then execute the npx command. The final script will be like the following:
hope this helps