Skip to content

Commit

Permalink
Update example filters in README.md
Browse files Browse the repository at this point in the history
JAXB example: org.glassfish.jaxb:jaxb-bom:2.4.0-b180830.0438
OpenJFX example: org.openjfx:javafx:13-ea+2
  • Loading branch information
mkroening authored Mar 19, 2019
1 parent fa17d54 commit 323dd95
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -92,8 +92,8 @@ For example, to disallow release candidates as upgradable versions a selection r
dependencyUpdates.resolutionStrategy {
componentSelection { rules ->
rules.all { ComponentSelection selection ->
boolean rejected = ['alpha', 'beta', 'rc', 'cr', 'm', 'preview'].any { qualifier ->
selection.candidate.version ==~ /(?i).*[.-]${qualifier}[.\d-]*/
boolean rejected = ['alpha', 'beta', 'rc', 'cr', 'm', 'preview', 'b', 'ea'].any { qualifier ->
selection.candidate.version ==~ /(?i).*[.-]${qualifier}[.\d-+]*/
}
if (rejected) {
selection.reject('Release candidate')
Expand All @@ -112,8 +112,8 @@ tasks.named<DependencyUpdatesTask>("dependencyUpdates") {
resolutionStrategy {
componentSelection {
all {
val rejected = listOf("alpha", "beta", "rc", "cr", "m", "preview")
.map { qualifier -> Regex("(?i).*[.-]$qualifier[.\\d-]*") }
val rejected = listOf("alpha", "beta", "rc", "cr", "m", "preview", "b", "ea")
.map { qualifier -> Regex("(?i).*[.-]$qualifier[.\\d-+]*") }
.any { it.matches(candidate.version) }
if (rejected) {
reject("Release candidate")
Expand Down

0 comments on commit 323dd95

Please sign in to comment.