when i try to launch ios simulator from command line by using
$ phonegap run ios
i get the below error
Error: ios-sim was not found. Please download, build and install version 1.5 or greater from https://github.com/phonegap/ios-sim into your path. Or 'brew install ios-sim' using homebrew: Link
i even tried copying the above ios-sim folder into my path. still getting an error.
Just type this command in Terminal: open -a Simulator. app to launch the most recent simulator. Type this command in Terminal to run the Simulator rigth from the its folder.
Best Solution:
Make sure you have XCode and its command line tools installed and accepted the license agreements
Download and install Homebrew by executing following command in terminal:
ruby -e "$(curl -fsSL https://raw.github.com/mxcl/homebrew/go/install)"
Install ios-sim via Homebrew by executing:
brew install ios-sim
Watch for error messages or upon successfull installation, you should be able to run the iOS Simulator:
phonegap run ios
Alternative Solution:
You could try installing ios-sim via npm:
sudo npm install ios-sim -g
npm install ios-sim
insteadTo run on simulator we need to install ios-sim and ios-deploy.
Following are steps to run on iOS emulator
Install ios-sim using npm by executing:
sudo npm install ios-sim -g
Install ios-deploy using npm by executing:
sudo npm install ios-deploy -g
Make sure your simulator is running
Final Command:
phonegap run ios --emulator
If need to run on particular simulator then following are steps:
Find out list of available simulators and their exact name
cordova emulate ios --list
now run on particular simulator using:
cordova emulate ios --target="XXXXXX"
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With