Exclude a specific dependency from springBoots `bootJar` gradle task
问题 I need to exclude a specific dependency from springBoots bootJar gradle task (similar to the provided scope in maven). I tried a custom configuration, but the dependency-which-should-not-be-in-bootJar is still included in the resulting jar. configurations{ provided implementation.extendsFrom provided } dependencies { // ... provided "dependency-which-should-not-be-in-bootJar" } jar { from configurations.compile - configurations.provided from configurations.runtime } bootJar { from