2011-08-30 81 views
1

可能重复:
Remove all unused resources from an android project的Android删除未使用的资源

我的一个项目,这是一个巨大的工程工作。它由许多图像和布局组成。 我需要从一个Command中删除项目中未使用的图像和布局。当我谷歌搜索http://code.google.com/p/android-unused-resources/我看到这个链接的Android。

但是没有太多相同的信息可用。 任何人都可以帮助我知道删除未使用的文件的步骤。

感谢

+0

你可以试试这个[PROGRAMM(https://github.com/matzuk/RemovingAndroidUnusedResources)的Android项目 –

回答

1

更新到ADT 16和使用Android Lint。这真是令人惊叹的工具。

Android Lint是ADT 16(和工具16)的新工具,它扫描Android项目源以查找潜在的错误。

Here are some examples of the types of errors that it looks for: 

- Missing translations (and unused translations) 
- Layout performance problems (all the issues the old layoutopt tool used to find, and more) 
- Unused resources 
- Inconsistent array sizes (when arrays are defined in multiple configurations) 
- Accessibility and internationalization problems (hardcoded strings, missing contentDescription, etc) 
- Icon problems (like missing densities, duplicate icons, wrong sizes, etc) 
- Usability problems (like not specifying an input type on a text field) 
- Manifest errors 
and many more.