1.1 --- a/build.gradle.kts Thu Dec 29 15:12:25 2022 +0100 1.2 +++ b/build.gradle.kts Fri Dec 30 13:21:09 2022 +0100 1.3 @@ -25,14 +25,18 @@ 1.4 from("src/main/resources") 1.5 } 1.6 1.7 +val libsAreProvided = true 1.8 kotlin { 1.9 sourceSets { 1.10 val main by getting { 1.11 dependencies { 1.12 - // change the following to compileOnly, if you already have them on your server 1.13 - implementation("jakarta.servlet.jsp.jstl:jakarta.servlet.jsp.jstl-api:3.0.0") 1.14 - implementation("org.glassfish.web:jakarta.servlet.jsp.jstl:3.0.1") 1.15 - implementation("org.postgresql:postgresql:42.5.1") 1.16 + arrayOf( 1.17 + "jakarta.servlet.jsp.jstl:jakarta.servlet.jsp.jstl-api:3.0.0", 1.18 + "org.glassfish.web:jakarta.servlet.jsp.jstl:3.0.1", 1.19 + "org.postgresql:postgresql:42.5.1" 1.20 + ).forEach { 1.21 + if (libsAreProvided) compileOnly(it) else implementation(it) 1.22 + } 1.23 compileOnly("jakarta.servlet:jakarta.servlet-api:6.0.0") 1.24 val flexmarkVersion = "0.64.0" 1.25 implementation("com.vladsch.flexmark:flexmark:${flexmarkVersion}")