File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -74,7 +74,8 @@ tasks {
7474 " mcVersion" to mcVersion,
7575 " pluginId" to pluginId,
7676 " author" to author,
77- " description" to project.description
77+ " description" to project.description,
78+ " bukkitLibraries" to ' [' + bukkitLibraries.joinToString(" ," ) { " \" $it \" " } + ' ]'
7879 )
7980 inputs.properties(props)
8081 filteringCharset = " UTF-8"
@@ -92,12 +93,19 @@ repositories {
9293 }
9394}
9495
96+ val bukkitLibraries = mutableListOf<String >()
97+
98+ fun DependencyHandlerScope.bukkitLibrary (dependencyNotation : Any ): Dependency ? {
99+ bukkitLibraries.add(dependencyNotation.toString())
100+ return compileOnly(dependencyNotation)
101+ }
102+
95103dependencies {
96104 @Suppress(" VulnerableLibrariesLocal" , " RedundantSuppression" )
97105 compileOnly(" io.papermc.paper:paper-api:${mcVersion} .build.+" )
98106
99- compileOnly (" org.apache.httpcomponents:httpclient:4.5.14" )
100- compileOnly (" org.apache.httpcomponents:httpmime:4.5.14" )
107+ bukkitLibrary (" org.apache.httpcomponents:httpclient:4.5.14" )
108+ bukkitLibrary (" org.apache.httpcomponents:httpmime:4.5.14" )
101109}
102110
103111java {
Original file line number Diff line number Diff line change @@ -4,5 +4,4 @@ main: io.github.kiber2009.plugin.contentapi.ContentApiPlugin
44api-version : $mcVersion
55author : $author
66description : $description
7- libraries :
8- - org.apache.httpcomponents:httpmime:4.5.14
7+ libraries : $bukkitLibraries
You can’t perform that action at this time.
0 commit comments