从进入的APK排除jar文件 [英] Exclude files in jar from going into the apk
问题描述
我最近增加了一些新的jar对我的机器人项目。一些罐子包含version.properties。其中一人甚至包含一个readme.txt。
I recently added some new jar's to my android project. Some of the jars contain version.properties. One of them even contains a README.TXT.
我怎么能告诉Eclipse / ADT /蚂蚁从渐入APK排除文件?
How can I tell eclipse/adt/ant to exclude files from getting into the apk?
显然,我可以解压APK,删除这些文件,ZIP,标志和放大器;溜索......但我希望在源头上解决这个问题。
Obviously I can unzip the apk, remove the files, zip, sign & zipline... but I was hoping to solve it at source.
推荐答案
如果您要创建您自己的项目的jar文件,右键单击项目 - >选择导出 - >在Java的选择JAR文件 - >然后你可以选择哪个文件的JAR被创建时包括。因此,取消任何资源,你不希望包含在JAR文件中。
If you are creating the jar files from your own project, you right click the project -> Select Export -> Under Java select JAR file -> Then you can choose which files to include when the jar gets created. So deselect whichever resources you don't want included in the Jar file.
如果这不是你在找什么,你也可以尝试在构建配置中添加这些文件进行排除文件夹。这里有一个链接可能会有所帮助。
If this isn't what you are looking for, you could also try adding those files to the exclusion folder in the build configuration. Here's a link that might help.
这篇关于从进入的APK排除jar文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!