Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(deps): Use Gradle version catalog #207

Merged
merged 1 commit into from
Sep 18, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 10 additions & 9 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ jar {
}

sonarLint {
setToolVersion('9.2.0.74516')
setToolVersion(libs.versions.sonarlint.core.get())
languages {
include('java')
}
Expand All @@ -80,13 +80,14 @@ strictNullCheck {
javadoc = """\
@author Jose Luis Leon
@since v1.0.2
""".stripIndent()
"""
.stripIndent()
}
source.addEclipse()
}

checkstyle {
setToolVersion('10.12.3')
setToolVersion(libs.versions.checkstyle.get())
}

dependencyLocking {
Expand All @@ -98,9 +99,9 @@ repositories {
}

dependencies {
sonarlintCorePlugins('org.sonarsource.java:sonar-java-plugin:7.24.0.32100')
sonarlintCorePlugins(libs.sonarlint.java)
constraints {
sonarlintCore('org.apache.tomcat.embed:tomcat-embed-core:9.0.80') {
sonarlintCore(libs.tomcat.jasper) {
because('version 9.0.75 has a security vulnerability')
}
}
Expand All @@ -109,10 +110,10 @@ dependencies {
testing {
suites {
test {
useJUnitJupiter('5.10.0')
useJUnitJupiter(libs.versions.junit.get())
dependencies {
implementation('org.assertj:assertj-core:3.24.2')
implementation('org.mockito:mockito-core:5.5.0')
implementation(libs.assertj)
implementation(libs.mockito)
}
}
}
Expand All @@ -126,7 +127,7 @@ prettyJupiter {
}

jacoco {
toolVersion('0.8.10')
setToolVersion(libs.versions.jacoco.get())
}

jacocoTestReport {
Expand Down
4 changes: 2 additions & 2 deletions gradle.lockfile
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,8 @@ org.apache.maven.doxia:doxia-logging-api:1.12.0=checkstyle
org.apache.maven.doxia:doxia-module-xdoc:1.12.0=checkstyle
org.apache.maven.doxia:doxia-sink-api:1.12.0=checkstyle
org.apache.tomcat.embed:tomcat-embed-core:9.0.80=sonarlintCoreClasspath
org.apache.tomcat.embed:tomcat-embed-el:9.0.75=sonarlintCoreClasspath
org.apache.tomcat.embed:tomcat-embed-jasper:9.0.75=sonarlintCoreClasspath
org.apache.tomcat.embed:tomcat-embed-el:9.0.80=sonarlintCoreClasspath
org.apache.tomcat.embed:tomcat-embed-jasper:9.0.80=sonarlintCoreClasspath
org.apache.tomcat:tomcat-annotations-api:9.0.80=sonarlintCoreClasspath
org.apache.xbean:xbean-reflect:3.7=checkstyle
org.apiguardian:apiguardian-api:1.1.2=java17TestCompileClasspath,java20TestCompileClasspath,testCompileClasspath
Expand Down
16 changes: 16 additions & 0 deletions settings.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,19 @@ plugins {
}

rootProject.name = 'maybe'

dependencyResolutionManagement {
versionCatalogs {
libs {
version('checkstyle', '10.12.3')
version('jacoco', '0.8.10')
version('junit', '5.10.0')
version('sonarlint-core', '9.2.0.74516')

library('assertj', 'org.assertj', 'assertj-core').version('3.24.2')
library('mockito', 'org.mockito', 'mockito-core').version('5.5.0')
library('sonarlint-java', 'org.sonarsource.java', 'sonar-java-plugin').version('7.24.0.32100')
library('tomcat-jasper', 'org.apache.tomcat.embed', 'tomcat-embed-jasper').version('9.0.80')
}
}
}