简体   繁体   中英

“Gradle Dependencies” cannot be correctly shown in 'Apache Tomcat' Run Configuration

My environment is as below:
Eclipse: Luna Service Release 1 (4.4.1) -- Build id: 20140925-1800
Gradle IDE: 3.6.3.201411271013-RELEASE

I have one project 'webapp' with gradle dependencies. If I create one 'Java Application' Run configuration, the "Gradle Dependencies" could be correctly displayed, and also be effective. See below pictures:
好

If I create one 'Apache Tomcat' Run Configuration to add the 'webapp' project in 'Classpath' tab, then the "Gradle Dependencies" couldn't be correctly displayed, and also not effective. See below pictures:
坏

Normally, I need to manually add all those gradle-dependencies jars in the 'Classpath' tab to solve the "ClassNotFoundException". Like this:
手册

However, it's not convenient.
Does anyone meet the same problem? Thanks.

使用Gradle eclipse-wtp插件生成Eclipse项目,然后将生成的项目导入Eclipse应该可以解决此问题:

gradle cleanEclipse eclipse eclipseWtp

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM