我的命令行shell不支持AAPT命令 [英] My Commandline shell does not support aapt command

查看:473
本文介绍了我的命令行shell不支持AAPT命令的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我工作的Andr​​iod开发并试图获得通过APK支持的活动清单。大部分的回答,我遇到说说下面的命令:

i am working on andriod development and trying to get the list of activities supported by an APK. Most of the answer that I come across talk about following command:

AAPT转储xmltree的Andr​​oidManifest.xml

aapt dump xmltree AndroidManifest.xml

但是,当我在我的命令行运行该命令它抛出以下错误:

But when I run that command on my command line it throws following error:

aapt is not recognized as an internal or external command

我能够成功运行其他亚行命令,我不知道什么是错的AAPT命令。在一个侧面说明,我在Windows 7环境下做开发。

I am able to run other adb commands successfully I am not sure what is wrong with aapt command. On a side note I am doing development in Windows 7 environment.

推荐答案

这意味着它是不是在你的PATH。请参阅这里的详细信息,如何添加路径变量。

That means it is not on your PATH. Please see here for details on how to add Path variables.

基本上这里的步骤。


  1. 要新增或编辑任何环境变量,在Windows 7中,你需要
    去系统属性第一。

  2. 然后,进入高级系统设置

  3. 在高级选项卡,点击环境变量按钮在底部。

  4. 双击路径,添加新路径进入变量值结尾。请确保你分开与价值;

您会希望您的平台及工具目录添加到PATH让你有其他工具为好。

You'll want to add your platform-tools and tools directories to the PATH so you have the other tools as well.

我的路径如下:
平台工具 - C:\\ Program Files文件\\的Andr​​oid \\ SDK \\平台工具
工具 - C:\\ Program Files文件\\的Andr​​oid \\ SDK \\工具

AAAPT特别是一个构建工具,所以你要添加目录中。这里的目录:
构建工具 - C:\\ Program Files文件\\的Andr​​oid \\ SDK \\集结工具\\ 18.1.0

AAAPT specifically is a Build Tool, so you'll want to add that directory as well. Here's the directory: Build Tools - C:\Program Files\Android\sdk\build-tools\18.1.0

这篇关于我的命令行shell不支持AAPT命令的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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