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

Project stack update #366

Merged
merged 3 commits into from
Apr 21, 2021
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
13 changes: 9 additions & 4 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@
* limitations under the License.
*/
plugins {
id("java-library")
id("com.bmuschko.docker-remote-api")
id("java")
id("io.gitlab.arturbosch.detekt") version "1.1.0"
id("io.gitlab.arturbosch.detekt") version "1.16.0"
id("io.knotx.distribution")
}

Expand All @@ -27,7 +27,13 @@ defaultTasks("redeployLocal")

dependencies {
subprojects.forEach { "dist"(project(":${it.name}")) }
"detektPlugins"("io.gitlab.arturbosch.detekt:detekt-formatting:1.1.0")
"detektPlugins"("io.gitlab.arturbosch.detekt:detekt-formatting:1.16.0")
}

java {
toolchain {
languageVersion.set(JavaLanguageVersion.of(8))
}
}

allprojects {
Expand All @@ -53,7 +59,6 @@ detekt {
config.from(file("detekt.yml"))
parallel = true
autoCorrect = true
failFast = true
}

apply(from = "gradle/javaAndUnitTests.gradle.kts")
Expand Down
6 changes: 3 additions & 3 deletions buildSrc/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ repositories {
}

dependencies {
implementation("com.moowork.gradle:gradle-node-plugin:1.2.0")
implementation("org.jetbrains.kotlin:kotlin-gradle-plugin:1.3.61")
implementation("com.bmuschko:gradle-docker-plugin:6.1.2")
implementation("com.moowork.gradle:gradle-node-plugin:1.3.1")
implementation("org.jetbrains.kotlin:kotlin-gradle-plugin:1.4.32")
implementation("com.bmuschko:gradle-docker-plugin:6.7.0")
implementation("io.knotx:knotx-gradle-plugins:0.1.4")
}
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ class SonarQubeWidget(
.stream()
.map { it as String }
.forEach { metricName ->
metrics.list
(metrics.list as List<*>)
.stream()
.map { it as JsonObject }
.filter {
Expand All @@ -79,7 +79,7 @@ class SonarQubeWidget(
}

private fun extractStatus(metrics: JsonArray): Widget.Status {
return metrics.list
return (metrics.list as List<*>)
.stream()
.map { it as JsonObject }
.filter { it.getString(version.getMetricKey()) == "alert_status" }
Expand Down
8 changes: 4 additions & 4 deletions cogboard-webapp/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@ plugins {
id("com.bmuschko.docker-remote-api")
}

node {
version = "10.16.0"
download = true
}
//node {
// version = "10.16.0"
// download = true
//}

val reactAppDestPath = "${rootProject.rootDir}/cogboard-app/src/main/resources"
tasks {
Expand Down
11 changes: 6 additions & 5 deletions detekt.yml
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,8 @@ complexity:
threshold: 60
LongParameterList:
active: true
threshold: 6
functionThreshold: 6
constructorThreshold: 6
ignoreDefaultParameters: false
MethodOverloading:
active: false
Expand Down Expand Up @@ -116,7 +117,7 @@ empty-blocks:
active: true
EmptyFunctionBlock:
active: true
ignoreOverriddenFunctions: false
ignoreOverridden: false
EmptyIfBlock:
active: true
EmptyInitBlock:
Expand Down Expand Up @@ -322,15 +323,15 @@ naming:
excludes: "**/test/**,**/androidTest/**,**/*.Test.kt,**/*.Spec.kt,**/*.Spek.kt"
parameterPattern: "[a-z][A-Za-z0-9]*"
excludeClassPattern: "$^"
ignoreOverriddenFunctions: true
ignoreOverridden: true
InvalidPackageDeclaration:
active: false
rootPackage: ""
MatchingDeclarationName:
active: true
MemberNameEqualsClassName:
active: false
ignoreOverriddenFunction: true
ignoreOverridden: true
ObjectPropertyNaming:
active: true
excludes: "**/test/**,**/androidTest/**,**/*.Test.kt,**/*.Spec.kt,**/*.Spek.kt"
Expand Down Expand Up @@ -461,7 +462,7 @@ style:
MagicNumber:
active: true
excludes: "**/test/**,**/androidTest/**,**/*.Test.kt,**/*.Spec.kt,**/*.Spek.kt"
ignoreNumbers: "-1,0,1,2"
ignoreNumbers: "-1,0,1,2,9,10,100"
ignoreHashCodeFunction: true
ignorePropertyDeclaration: false
ignoreConstantDeclaration: true
Expand Down
3 changes: 3 additions & 0 deletions gradle.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
version=1.0.4

# JDK
javaSupport.version=8

# Knot.x Docker image version (https://hub.docker.com/r/knotx/knotx)
knotx.version=2.1.0
knotx.conf=knotx
Expand Down
2 changes: 1 addition & 1 deletion gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-5.6.4-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-6.8.3-bin.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists