java - Gradle jettyRuns works but no dependencies in Eclipse -


i trying make application work , building configured in gradle. when use jettyrun in cmd run application works expected when open actuall code in eclipse missing of these dependecies such spring or hibernate , others... unsure how resolve this

the gradle.build looks this

apply plugin: 'java' apply plugin: 'war' apply plugin: 'eclipse-wtp' apply plugin: 'jetty'  // jdk 7 sourcecompatibility = 1.8 targetcompatibility = 1.8  repositories {     mavenlocal()     mavencentral() }   dependencies {       compile 'ch.qos.logback:logback-classic:1.1.3'      compile 'org.springframework:spring-webmvc:4.1.6.release'      compile 'javax.servlet:jstl:1.2'      compile 'org.springframework:spring-orm:4.1.6.release'      compile 'org.springframework:spring-tx:4.1.6.release'      compile 'org.springframework:spring-jdbc:4.1.6.release'      compile 'mysql:mysql-connector-java:5.1.31'      compile 'org.hibernate:hibernate-core:4.3.10.final'      compile 'org.hibernate:hibernate-entitymanager:4.3.10.final'    }  // embeded jetty testing jettyrun{     contextpath = "etnshop"     httpport = 8080 }  jettyrunwar{     contextpath = "etnshop"     httpport = 8080 }  //for eclipse ide eclipse {    wtp {     component {        //define context path, default project folder name       contextpath = 'etnshop'      }    } } 

using command gradle eclipse fixed problem.


Comments