1 打release包時 minifyEnabled 和 shrinkResources 都開啓時 報如下錯誤:
1 : app\build\intermediates\res\resources-lemon_wap-LemonReader-stripped.ap_' specified for property 'resourceFile' does not exist
2 :Xml parsing errors; 前言中不允許有內容:igonring
相關日誌:Failed to shrink resources: org.xml.sax.SAXParseException; lineNumber: 1; co
Line 1 in XML document from class path resource [bean.xml] is invalid; nested exception is org.xml.sax.SAXParseException;
解決辦法:1 檢測所有新加的xml頭部是否添加了
<?xml version="1.0" encoding="utf-8"?>
2 <?xml version="1.0" encoding="utf-8"?> 前是否有空格