Skip to content

Instantly share code, notes, and snippets.

@bigdaz
Last active October 15, 2018 21:18
Show Gist options
  • Save bigdaz/7aa8107e3e9954625a89cadb1d2ce84e to your computer and use it in GitHub Desktop.
Save bigdaz/7aa8107e3e9954625a89cadb1d2ce84e to your computer and use it in GitHub Desktop.
plugins {
id 'java'
}
repositories {
mavenCentral()
}
dependencies {
implementation platform("org.springframework.boot:spring-boot-dependencies:2.0.5.RELEASE")
implementation "org.springframework.boot:spring-boot-starter-data-jpa"
// Use a newer version of the spring-data-releasetrain
implementation platform("org.springframework.data:spring-data-releasetrain:Lovelace-RELEASE")
}
plugins {
id 'java'
}
repositories {
mavenCentral()
}
dependencies {
implementation enforcedPlatform("org.springframework.boot:spring-boot-dependencies:2.0.5.RELEASE")
implementation "org.springframework.boot:spring-boot-starter-data-jpa"
// Use a newer version of the spring-data-releasetrain.
implementation enforcedPlatform("org.springframework.data:spring-data-releasetrain:Lovelace-RELEASE")
// Remove any of the dependencies declared in `spring-data-releasetrain` from `spring-boot-dependencies`.
// Note that this looks simple here, because we assume they all have a matching group.
// This may not be the case.
components {
withModule("org.springframework.boot:spring-boot-dependencies") {
allVariants {
withDependencyConstraints { deps ->
deps.removeAll { it.group == 'org.springframework.data' }
}
}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment