File tree Expand file tree Collapse file tree 1 file changed +20
-0
lines changed
spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin Expand file tree Collapse file tree 1 file changed +20
-0
lines changed Original file line number Diff line number Diff line change
1
+ import org.gradle.plugins.ide.eclipse.EclipsePlugin
2
+ import org.gradle.plugins.ide.eclipse.model.Classpath
3
+ import org.gradle.plugins.ide.eclipse.model.Library
4
+
1
5
plugins {
2
6
id " java-gradle-plugin"
3
7
id " maven-publish"
@@ -138,3 +142,19 @@ artifacts {
138
142
toolchain {
139
143
maximumCompatibleJavaVersion = JavaLanguageVersion . of(20 )
140
144
}
145
+
146
+ plugins. withType(EclipsePlugin ) {
147
+ eclipse {
148
+ classpath. file { merger ->
149
+ merger. whenMerged { content ->
150
+ if (content instanceof Classpath ) {
151
+ content. entries. each { entry ->
152
+ if (entry instanceof Library && (entry. path. contains(" gradle-api-" ) || entry. path. contains(" groovy-" ))) {
153
+ entry. entryAttributes. remove(" test" )
154
+ }
155
+ }
156
+ }
157
+ }
158
+ }
159
+ }
160
+ }
You can’t perform that action at this time.
0 commit comments