'phonegap' is not recognized as an interna

2019-02-13 04:08发布

I am trying to install phonegap 3.1 version using node.js, Command line interface.

Phonegap got installed on the machine, but I am not able to use phonegap command. When I list packages, I can see phonegap, but can not run command to create project.

System config : OS : WIN XP, node version : 0.10.22, npm version : 1.3.14, phonegap version : 3.1.0,

EDIT :

Error Message

C:>phonegap

'phonegap' is not recognized as an internal or external command, operable program or batch file.

C:>npm -g list phonegap

C:\Documents and Settings\vishal.kardode\Application Data\npm └── phonegap@3.1.0-0.15.0

7条回答
ゆ 、 Hurt°
2楼-- · 2019-02-13 05:07

The Problem is you need to set environment variable.

Start -> Control Panel -> System and Security -> System -> Environment variables

or

Mycomputer -> Right Click -> properties -> Advance System settings -> Environment variables

under User variables for youruser:

Path:
  %SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;%SYSTEMROOT%
  \System32\WindowsPowerShell\v1.0\;C:\Users\user1\AppData\Roaming\npm\`

Temp:
  %USERPROFILE%\AppData\Local\Temp

If you are copy pasting it wont work. Follow my previous answer to configure this. If you
are not getting this set up let reply.

查看更多
登录 后发表回答