Sunday, 8 September 2013

PhoneGap Mac CLI local install failed because of Node version

PhoneGap Mac CLI local install failed because of Node version

So I want to debug my Phonegap webapp locally in Xcode.
I follow the step here and here, and launch in MAC CLI
$ sudo npm install -g phonegap
BUT install failed and CLI result get lots of errors with the first one is :
engine phonegap@2.9.0rc1-0.12.0: wanted: {"node":">=0.10.0"} (current:
{"node":"v0.8.8","npm":"1.1.59"})
I understand my node version is too old : 0.8.8
node --version



I try to update but I am stuck with those 2 methods here and bot in errors
for me :
BREW
Tried Homebrew but did not work :
$ brew upgrade node
Error: node-0.8.8 already installed
NPM
As I found here
Upgrading Node.js to latest version
How to update node.js, npm and all other dependencies?
$ sudo npm install -g n
$ sudo n stable
sudo: n: command not found

No comments:

Post a Comment