0
如何在使用Gradle構建Eclipse項目時從構建路徑中排除軟件包?Gradle - 從Eclipse項目構建路徑中排除軟件包
如何在使用Gradle構建Eclipse項目時從構建路徑中排除軟件包?Gradle - 從Eclipse項目構建路徑中排除軟件包
有在文檔描述的一些示例: http://gradle.org/docs/current/dsl/org.gradle.plugins.ide.eclipse.model.EclipseClasspath.html
eclipse {
//if you want parts of paths in resulting file to be replaced by variables (files):
pathVariables 'GRADLE_HOME': file('/best/software/gradle'), 'TOMCAT_HOME': file('../tomcat')
classpath {
//you can tweak the classpath of the eclipse project by adding extra configurations:
plusConfigurations += configurations.provided
//you can also remove configurations from the classpath:
minusConfigurations += configurations.someBoringConfig
//if you don't want some classpath entries 'exported' in eclipse
noExportConfigurations += configurations.provided
//if you want to append extra containers:
containers 'someFriendlyContainer', 'andYetAnotherContainer'
//customizing the classes output directory:
defaultOutputDir = file('build-eclipse')
//default settings for dependencies sources/javadoc download:
downloadSources = true
downloadJavadoc = false
}
}