我正在使用 sencha cmd 6 并尝试在 https://docs.sencha.com/cmd/6.x/cordova_phonegap.html的帮助下构建本机应用程序
我使用以下命令生成了 Ext 6+ 通用应用程序:
sencha -sdk /path/to/Framework generate app MyApp /path/to/MyApp
然后我在 app.json 中添加了以下代码 -
"builds": {
"classic": {
"toolkit": "classic",
"theme": "theme-triton",
"sass": {
// "save": "classic/sass/save.json"
}
},
"native": {
"toolkit": "modern",
"theme": "theme-cupertino",
"packager": "phonegap",
"phonegap": {
"config": {
"platforms": "ios android",
"id": "com.mydomain.MyApp"
}
}
}
}
但是在运行 sencha app build android 之后,我得到了以下异常 -
BUILD FAILED
java.lang.NullPointerException
at org.a
pache.tools.ant.helper.SingleCheckExecutor.executeTargets(SingleCheckExecutor.java:38)
同样根据从 sencha doc 开发 PhoneGap 应用程序中的建议,我使用以下代码修改了 app.json -
"builds": {
"native": {
"packager": "phonegap",
"phonegap" : {
"config": {
"platforms": "ios android",
"id": "com.mydomain.MyApp"
}
}
}
}
但在此之后,我的控制台上出现了以下异常 -
Failed to resolve dependency Ext.app.Application for file MyApp.Application
BUILD FAILED
com.sencha.exceptions.ExNotFound: Unknown definition for dependency : Ext.app.Application