如何将android添加到cordova平台?路径错误? [英] How to add android to cordova platform? PATH error?

查看:27
本文介绍了如何将android添加到cordova平台?路径错误?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试将 android 添加为 Cordova 平台,以便我可以使用 phonegap 构建应用程序.当我尝试添加 android 时:

I am trying to add android as a cordova platform so that I can build apps with phonegap. When I tried to add android thus:

$ cordova platform add android

我收到此错误消息:

[错误:命令 android 失败.确保你有最新的安装了 Android SDK,以及 android 命令(在 tools/文件夹)添加到您的路径中.输出:/bin/sh: android: command not找到]

[Error: The command android failed. Make sure you have the latest Android SDK installed, and the android command (inside the tools/ folder) added to your path. Output: /bin/sh: android: command not found ]

我确实安装了最新的 Android SDK,所以我想我需要将 android 添加到我的路径中.我已经用谷歌搜索了如何做到这一点,并搜索了这个论坛,但我对命令行的使用知之甚少,我不明白答案.

I do have the latest Android SDK installed, so I suppose I need to add android to my path. I've googled on how to do that, and searched this forum, but I have little knowledge of command line use and I don't understand the answers.

如果有人能提供非常简单的步骤来将 android 添加到我的路径中,我将不胜感激.

If someone could provide very simple steps to add android to my path, I would be most grateful.

推荐答案

PhoneGap Doc 上有分步说明.在这里查看,然后去到步骤 3B.我链接到 PhoneGap 的 2.8 版本,因为从快速浏览来看,它似乎没有解释如何在 3.0 版本的文档中设置 PATH.

There's step-by-step instructions on the PhoneGap Doc's. Check it out here, and then go to Step 3B. I linked to the 2.8 version of PhoneGap since from a quick look it doesn't seem to explain how to set up PATH on the 3.0 version docs.

这篇关于如何将android添加到cordova平台?路径错误?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆