使用我的应用程序在Phonegap中创建一个项目作为开始 [英] Create a project using my app as a starter in Phonegap
问题描述
我的应用程序的git仓库只包含 www
文件夹,因此它如下所示:
My app's git repository contain only the www
folder and so it looks like this:
css
img
js
res
config.xml
icon.png
index.html
要开始开发,我需要:
- 将我的应用程式复制到
www-app
- 建立phonegap应用程式
phonegap create testapp com.example.testapp Test
- 删除
testapp / www
并复制/ code>到
testapp / www
- Clone my app into
www-app
- Create a phonegap app
phonegap create testapp com.example.testapp "Test"
- remove
testapp/www
and copywww-app
totestapp/www
到方法来设置这个?也许我可以指定一个项目从 phonegap create
而不是 phonegap-start 项目。
Is there a easier to way to set this up? Maybe I can specify a project to build from on phonegap create
instead of the phonegap-start project.
推荐答案
我没有尝试过这个与phonegap CLI,但cordova CLI可以复制来自项目的初始内容 - copy-from
选项,所以像 phonegap create testapp com.example.testappTest--copy -from www-app
可能会工作。或者,您可以使用Cordova CLI通过 cordova create testapp com.example.testappTest--copy-from www-app
创建项目,然后继续使用phonegap。
I have not tried this with phonegap CLI but cordova CLI can copy the initial contents from a project with --copy-from
option, so something like phonegap create testapp com.example.testapp "Test" --copy-from www-app
may possibly work. Alternately you can create the project using Cordova CLI with cordova create testapp com.example.testapp "Test" --copy-from www-app
and continue with phonegap.
这篇关于使用我的应用程序在Phonegap中创建一个项目作为开始的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!