使用android-resource-remover遇到的问题
2015-10-19 11:04
447 查看
直接使用会报错:
应该换种使用方式,指定lint:
这样就使用成功了:
C:\Users\Administrator\Desktop\GitHub\android-resource-remover-master\test\android_app>lint --check UnusedResources ./ --xml lint-result.xml && android-resource-remover Scanning android_app: ................ Scanning android_app (Phase 2): ........... Wrote XML report to C:\Users\Administrator\Desktop\GitHub\android-resource-remov er-master\test\android_app\lint-result.xml Lint found 1 errors and 12 warnings Traceback (most recent call last): File "c:\python27\lib\runpy.py", line 162, in _run_module_as_main "__main__", fname, loader, pkg_name) File "c:\python27\lib\runpy.py", line 72, in _run_code exec code in run_globals File "C:\Python27\Scripts\android-resource-remover.exe\__main__.py", line 9, i n <module> File "c:\python27\lib\site-packages\android_clean_app.py", line 141, in main lint_result_path, app_dir, ignore_layouts = run_lint_command() File "c:\python27\lib\site-packages\android_clean_app.py", line 77, in run_lin t_command call_result = subprocess.call([lint, app_dir, '--xml', lint_result]) File "c:\python27\lib\subprocess.py", line 522, in call return Popen(*popenargs, **kwargs).wait() File "c:\python27\lib\subprocess.py", line 710, in __init__ errread, errwrite) File "c:\python27\lib\subprocess.py", line 958, in _execute_child startupinfo) WindowsError: [Error 2]
应该换种使用方式,指定lint:
android-resource-remover --lint D:\DevUtils\Android\SDK\tools\lint.bat --xml lint-result.xml
这样就使用成功了:
C:\Users\Administrator\Desktop\GitHub\android-resource-remover-master\test\andro id_app>android-resource-remover --lint D:\DevUtils\Android\SDK\tools\lint.bat -- xml lint-result.xml removing resource: .\res\anim\anim_missing.xml removing resource: .\res\animator\animator_missing.xml removing resource: .\res\color\color_missing.xml removing ('dimen', 'missing_dimen') from resource .\res\values\dimens.xml removing resource: .\res\drawable\drawable_missing.xml removing resource: .\res\drawable-hdpi\ic_launcher.png removing resource: .\res\drawable-ldpi\ic_launcher.png removing resource: .\res\drawable-mdpi\ic_launcher.png removing resource: .\res\drawable-xhdpi\ic_launcher.png removing resource: .\res\layout\layout_missing.xml removing resource: .\res\menu\menu_missing.xml removing ('string', 'missing') from resource .\res\values\strings.xml removing ('string', 'missing') from resource .\res\values-fr\strings.xml removing ('string', 'extra_translation') from resource .\res\values-fr\strings.x ml removing resource: .\res\xml\xml_missing.xml
相关文章推荐
- 使用C++实现JNI接口需要注意的事项
- Android IPC进程间通讯机制
- Android Manifest 用法
- [转载]Activity中ConfigChanges属性的用法
- Android之获取手机上的图片和视频缩略图thumbnails
- Android之使用Http协议实现文件上传功能
- Android学习笔记(二九):嵌入浏览器
- android string.xml文件中的整型和string型代替
- i-jetty环境搭配与编译
- android之定时器AlarmManager
- android wifi 无线调试
- Android Native 绘图方法
- Android java 与 javascript互访(相互调用)的方法例子
- android 代码实现控件之间的间距
- android FragmentPagerAdapter的“标准”配置
- Android"解决"onTouch和onClick的冲突问题
- android:installLocation简析
- android searchView的关闭事件
- SourceProvider.getJniDirectories