Eclipse Gradle向导使用SubFolder -lib创建项目

Eclipse Gradle向导使用SubFolder -lib创建项目

问题描述:

当我在Eclipse中创建Gradle项目时,结果是带有自动创建的-lib文件夹的嵌套项目.关于为什么要创建它的任何想法?

When I create a Gradle project in Eclipse the result is a nested project with a -lib folder created automatically. Any ideas on why this is being created?

我在Eclipse 2021-03上使用最新的gradle版本7.0-rc-1对此进行了测试,并重现了您创建带有lib子项目的嵌套项目的问题.然后,我创建了一个新的Eclipse项目,指定要使用的Gradle版本6.6,并且未嵌套结果项目.我建议尝试使用Gradle 6.6,看看是否得到与我相同的行为.这可能会修复您的项目.

I tested this on Eclipse 2021-03 using the latest gradle version 7.0-rc-1 and reproduced your issue where a nested project with a lib subproject was created. I then made a new Eclipse project specifying Gradle version 6.6 to be used and the resulting project was not nested. I suggest trying Gradle 6.6 and seeing if you get the same behavior I got. This might fix your project.

也可以尝试从命令行运行 gradle init 命令,并查看在那里的项目结构.我在PC上进行了测试,将Gradle 5.6作为默认版本,并获得了非嵌套结构.当然,您总是可以在几分钟内手动修改gradle项目,以免被嵌套.

Also try running the gradle init command from the command line and see what project structure you get there. I tested this on my PC where I have gradle 5.6 as the default version and got a non nested structure. You can of course always manually modify your gradle project in a few minutes to not be nested.