我是新的gradle和尝试使用gradle插件在eclipse。
使用联机项目生成器https://gwt-project-generator.cfapps.io/创建java gwt项目。

它很好地导入了所有依赖项。
现在我试图把这个项目从演示重命名为分级演示,我很困惑。它每次都会自动将名称恢复为演示。在build.gradle文件中,我没有看到任何表示名称强制执行的内容。
有什么指示吗?
buildscript {
repositories {
jcenter()
}
dependencies {
classpath 'de.richsource.gradle.plugins:gwt-gradle-plugin:0.6'
}
}
apply plugin: 'gwt'
apply plugin: 'war'
// In this section you declare where to find the dependencies of your project
repositories {
jcenter()
}
repositories { mavenCentral() }
// In this section you declare the dependencies for your production and test code
dependencies {
providedCompile('fr.lteconsulting:angular2-gwt:1.6')
providedCompile('com.google.dagger:dagger-gwt:2.8')
providedCompile('org.jboss.gwt.elemento:elemento-core:0.5')
providedCompile('com.vaadin.polymer:vaadin-gwt-polymer-elements:1.7.0.0')
providedCompile('org.gwtbootstrap3:gwtbootstrap3:0.9.3')
providedCompile('com.github.tdesjardins:gwt-ol3:2.9.0')
providedCompile('com.googlecode.gwtquery:gwtquery:2.1.0')
providedCompile('com.github.gwtreact:gwt-react:0.3.0')
providedCompile('com.gwidgets:gwty-leaflet:0.4')
providedCompile('com.sksamuel.jqm4gwt:jqm4gwt-remote:2.1.0')
providedCompile('com.intendia.gwt:rxjava-gwt:1.0.14-beta1')
testCompile('junit:junit:4.11')
testCompile('com.google.gwt.gwtmockito:gwtmockito:1.1.6')
}
gwt {
gwtVersion='2.8.0'
modules 'com.ainosoft.firstGradleGwt'
maxHeapSize = "1024M"
superDev {
noPrecompile=true
}
}它还显示了gwt项目配置中缺少的生成器。

发布于 2017-08-21 09:14:57
将此添加到build.gradle中
apply plugin: 'eclipse'
eclipse {
project {
name = 'some-better-name'
}
}发布于 2020-09-10 04:39:19
Eclipse的Refactor->Rename...似乎不能很好地处理Gradle项目。
settings.gradle并相应地修改rootProject.name。
例如:
rootProject.name =“coolproject”
确保这是在settings.gradle__,而不是build.gradle__!Gradle->Refresh Gradle Project发布于 2022-09-16 12:28:57
在eclipse中重命名Gradle项目。
1)右键单击项目->,重构->,重命名新名称,并勾选更新引用,然后单击ok
2)打开settings.gradle并修改rootProject.name accordingly.And保存它
例如:
rootProject.name =“coolproject”
3)右键单击项目,然后单击Gradle->Refresh Gradle Project。
4)在此之后也显示错误,然后关闭eclipse并再次重新打开。
https://stackoverflow.com/questions/45793275
复制相似问题