我從命令行構建android應用程序。我需要簽署我的應用程序才能在設備上安裝內置的.apk文件。爲此,我需要在ant.properties文件中寫入key.store和key.alias。但ant.properties文件丟失。所以任何人都知道請讓我知道。安卓項目中缺少ant.properties文件
3
A
回答
7
運行android update project -p .
或
具有以下內容
# This file is used to override default values used by the Ant build system.
#
# This file must be checked in Version Control Systems, as it is
# integral to the build system of your project.
# This file is only used by the Ant script.
# You can use this to override default values such as
# 'source.dir' for the location of your java source folder and
# 'out.dir' for the location of your output folder.
# You can also use it define how the release builds are signed by declaring
# the following properties:
# 'key.store' for the location of your keystore and
# 'key.alias' for the name of the key to use.
# The password will be asked during the build when you use the 'release' target.
android.library.reference.1=###link to any external libraries####
key.alias=android_key
key.store.password==#########
config.logging=false
key.store=#########path to keystore##########
key.alias.password=######
相關問題
- 1. 安卓:R.java缺少
- 2. 在gradle安卓項目中缺少android版本
- 3. 建築安卓:system.img缺少
- 4. Eclipse項目中缺少.classpath文件
- 5. 在項目中缺少database.yml文件
- 6. iOS - Xcode 4項目中缺少文件
- 7. 安卓項目中的.java文件
- 8. 安卓工具缺少硬件選項菜單按鈕
- 9. skia缺少xcode項目文件
- 10. 缺少文件的所有者項目
- 11. 項目缺少假文件夾MYECLIPSE
- 12. 安卓選項菜單中缺少分隔符
- 13. 安卓工作室缺少文件parser17.rsc
- 14. 安卓swipelist缺少的屬性
- 15. 缺少'android項目'
- 16. 缺少SSDT項目
- 17. 項目中缺少guiddef.h
- 18. iOS項目中缺少AddressBook.framework
- 19. ant.properties擺脫文件
- 20. 在Eclipse中缺少「添加文件到黑莓項目」選項
- 21. 如何解決IOS中DTCoreText項目中缺少DTWeakSupport.h文件?
- 22. 缺少項目亞型F#項目
- 23. 安卓解密:最後塊(16個字節)中缺少結果文件
- 24. Azure軟件包缺少項目dll
- 25. Eclipse java項目缺少插件
- 26. 缺少工具箱項目
- 27. eclipse -restore缺少項目
- 28. VC6項目缺少msvcp71d.dll?
- 29. DbSet:缺少添加項目
- 30. 缺少org.apache.commons.dbcp包Maven項目
你確定你是用Ant構建您的APK手動創建
ant.properties
文件?您的項目中是否爲.gradle文件? – Casabian是的,我正在建設與螞蟻..我的項目的根沒有這樣的.grade文件.. – user2652046
我手動複製一個ant.properties文件,然後我寫這裏key.store和key.alias來簽署應用程序。當我使用ant構建文件時,它會生成未簽名的.apk文件。它也在cmd中同時發生錯誤。錯誤是「密鑰庫的值不是有效的,它必須是單個路徑」 – user2652046