1

I am very frustrated with the installation. Neither book nor online documentation seem to work. I am new with the OS. I have installed Xcode from AppStore. Suggested here http://docs.phonegap.com/en/2.0.0/guide_getting-started_ios_index.md.html#Getting%20Started%20with%20iOS "Install the Xcode Command Line Tools (Xcode Preferences -> Downloads -> Components -> Command Line Tools -> Install)." Just does not exists. There is NO "Command Line Tools"

Next I tried approach recommended here https://cordova.apache.org/#getstartedhttps://cordova.apache.org/#getstarted The installation seem was successful, but I cannot enter command 'cordova' -- it's NOT FOUND.

Please, please, help me!

Is that Apple want to get rid of the third party development tools like phonegap (or flash) and make everything so difficult on purpose?

  • See if this answer helps http://stackoverflow.com/questions/17975330/bash-cordova-command-not-found-or-bash-phonegap-command-not-found – Gajendra Naidu Dec 17 '15 at 08:58
  • Do you know about the `$PATH` environment variable and how to set it up? If not you will need to step back as that's something I would expect a user to know, let alone a developer. – trojanfoe Dec 17 '15 at 09:07
  • Yes, I know about the $PATH. I don't know why the installation process cannot set it or at least say that I have to set it myself and why I have to search for the directory where it was installed. So many useless messages - could add one meaninful? – Pochemuchka Dec 17 '15 at 13:21

1 Answers1

1

Cordova has been renamed to Phonegap, so some guides might give incorrect information.

Try the following:

1) open Terminal app and write:

gcc

This will bring up the window, where you are asked whether you want to install the Developer Tools.

2) If you failed to successfully install Cordova (Phonegap?), then visit this page

But everything you really need to do is writing this in Terminal:

sudo npm install -g phonegap

3) Now, if you want to create a Cordova-based app for ios, run the following in Terminal:

cd Desktop
phonegap create myTestApp
cd myTestApp
phonegap run ios

A new Folder with name 'myTestApp' has been created on Desktop.

4) Go and have a look inside the created folder.

Your ios project template is in Desktop ~> myTestApp ~> platforms ~> ios ~> Hello World.xcodeproj

OlDor
  • 1,460
  • 12
  • 18
  • gcc predictably gives error message: clang: error: no input files – Pochemuchka Dec 17 '15 at 14:35
  • I did n't see any error messages when installed, so I assume that cordova is installed correctly MacBook-Air:Desktop dorasoft$ phonegap create MyTestPhG Creating a new cordova project. 2) MacBook-Air:Desktop dorasoft$ cd MyTestPhG/ 3)MacBook-Air:MyTestPhG dorasoft$ phonegap add ios Error: Cordova does not know add; try `cordova help` for a list of all the available commands. Seems to me that Cordova has NOT been renamed back to PhoneGap... – Pochemuchka Dec 17 '15 at 14:42
  • for Developer tools try 'xcode-select --install' in Terminal. have a look here -- http://apple.stackexchange.com/questions/133147/how-to-install-command-line-developer-tools-in-yosemite – OlDor Dec 17 '15 at 14:45
  • in some cases they ask for commands starting with "cordova", but in some cases they use "phonegap". I assume they didn't have time to change all the command set from 'cordova' to 'phonegap'. – OlDor Dec 17 '15 at 14:46
  • oh, yes, sure, the command is 'phonegap run ios', NOT 'phonegap add ios'. Sorry. I have edited my answer. – OlDor Dec 17 '15 at 14:53
  • -MacBook-Air:MyTestPhG dorasoft$ phonegap run ios [phonegap] executing 'cordova platform add --save ios'... [phonegap] completed 'cordova platform add --save ios' [phonegap] executing 'cordova run ios'... [phonegap] completed 'cordova run ios' And what suppose to happen? Do I have phonegap template in Xcode now? – Pochemuchka Dec 17 '15 at 17:57
  • But, I still don't have phone gap template in Xcode and when I tried to run phone gap run iPhone - I ve got errors -- unknown platform. – Pochemuchka Dec 17 '15 at 22:34