我試圖通過Grails服務器提供zip'ed應用程序來測試Firefox OS設備上的應用程序。該文件是這樣服務的:Firefox操作系統:MANIFEST_PARSE_ERROR
response.setContentType("application/x-web-app-manifest+json")
File file = new File("/path/to/application/package.zip")
response.setHeader("Content-disposition", "attachment;filename=${file.name}")
response.outputStream << file.bytes
我可以在桌面瀏覽器上下載zip,就好像它正在下載設備一樣。下載後,會出現以下錯誤:
MANIFEST_PARSE_ERROR
下面就一起來看看清單:
{
"version": "0.1",
"name": "App Name",
"description": "App Description",
"launch_path": "/target/index.html",
"icons": {
"16": "/img/icons/mortar-16.png",
"48": "/img/icons/mortar-48.png",
"128": "/img/icons/mortar-128.png"
},
"developer": {
"name": "Example Dev",
"url": "http://example.com"
},
"installs_allowed_from": ["*"],
"default_locale": "en",
"permissions": {
}
}
真棒,謝謝。這解決了它。 – kz3