我用我的方式完成了入门指南-- http://code.google.com/p/playn/wiki/GettingStarted --但是在“在App上运行你的新游戏”这一点上我很困惑。指南说“为了在Google上运行你的游戏,我们可以使用kindleit.net maven-gae。”我看过http://www.kindleit.net/maven_gae_plugin/,但不明白我应该做什么。
1)有人能指出我需要做些什么才能得到/安装maven-gae-plugin的正确方向吗?我想这是Maven的插件,但不知道该怎么办?
发布于 2012-02-09 18:43:26
要在项目中使用maven-gae-plugin,需要将以下内容添加到pom.xml的存储库部分
<repository>
<id>maven-gae-plugin-repo</id>
<name>maven-gae-plugin repository</name>
<url>http://maven-gae-plugin.googlecode.com/svn/repository</url>
</repository>在pom.xml的build/plugins部分中添加以下插件:
<plugin>
<groupId>net.kindleit</groupId>
<artifactId>maven-gae-plugin</artifactId>
<version>0.9.2</version>
<configuration>
<serverid>appengine.google.com</serverId>
</configuration>
</plugin>确保以下内容在html/src/webapp/WEB/appEngine-web.xml文件中
<?xml version="1.0" encoding="UTF-8"?>
<appengine-web-app xmlns="http://appengine.google.com/ns/1.0">
...
<!-- This is the unique id of your GAE application -->
<application>my-unique-app-name</application>
<!-- This variable is defined in your POM file -->
<version>${gae.application.version}</version>
...
</appengine-web-app>并在您的~/.m2/setings.xml中添加以下内容
<settings>
...
<servers>
<server>
<id>appengine.google.com</id>
<username>myname@gmail.com</username>
</server>
</servers>
...
</settings>然后从gae:deploy项目中的html文件夹运行mvn PlayN。请注意,如果您的代码依赖于使用GAE的数据存储,那么这本身并不能处理让DataNucleus增强您的域对象的任务。那是一个完全不同的蜡球
https://stackoverflow.com/questions/9215977
复制相似问题