forked from andrepl/ChunkSpawnerLimiter
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #32 from sarhatabaot/gradle
Port to gradle & update action
- Loading branch information
Showing
12 changed files
with
486 additions
and
221 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
# This workflow will build a Java project with Maven, and cache/restore any dependencies to improve the workflow execution time | ||
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-maven | ||
|
||
name: Java CI with Gradle (kotlin) | ||
|
||
on: | ||
push: | ||
branches: [ master ] | ||
pull_request: | ||
branches: [ master ] | ||
|
||
permissions: | ||
contents: read | ||
|
||
jobs: | ||
build: | ||
|
||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Set up JDK 8 | ||
uses: actions/setup-java@v4 | ||
with: | ||
java-version: '8' | ||
distribution: 'temurin' | ||
- name: Build with Gradle | ||
uses: gradle/gradle-build-action@585b565652cefbba63202a7f927df0ff99f34001 | ||
with: | ||
arguments: build | ||
|
||
dependency-submission: | ||
|
||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: write | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Set up JDK 8 | ||
uses: actions/setup-java@v4 | ||
with: | ||
java-version: '8' | ||
distribution: 'temurin' | ||
|
||
# Generates and submits a dependency graph, enabling Dependabot Alerts for all project dependencies. | ||
# See: https://github.com/gradle/actions/blob/main/dependency-submission/README.md | ||
- name: Generate and submit dependency graph | ||
uses: gradle/actions/dependency-submission@417ae3ccd767c252f5661f1ace9f835f9654f2b5 # v3.1.0 |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,3 +4,6 @@ target | |
*.iml | ||
sonar.txt | ||
dependency-reduced-pom.xml | ||
|
||
.gradle | ||
build |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
import net.minecrell.pluginyml.bukkit.BukkitPluginDescription | ||
|
||
plugins { | ||
java | ||
alias(libs.plugins.shadow) | ||
alias(libs.plugins.plugin.yml) | ||
} | ||
version = "4.3.5" | ||
description = "Limit entities in chunks." | ||
|
||
|
||
repositories { | ||
mavenCentral() | ||
maven("https://hub.spigotmc.org/nexus/content/repositories/snapshots/") | ||
maven("https://repo.codemc.org/repository/maven-public") | ||
maven("https://repo.aikar.co/content/groups/aikar/") | ||
} | ||
|
||
dependencies { | ||
compileOnly(libs.spigot.api) | ||
|
||
implementation(libs.bstats) | ||
implementation(libs.acf) | ||
implementation(libs.annotations) | ||
} | ||
|
||
bukkit { | ||
name = "ChunkSpawnerLimiter" | ||
main = "com.cyprias.chunkspawnerlimiter.ChunkSpawnerLimiter" | ||
version = project.version.toString() | ||
apiVersion = "1.14" | ||
authors = listOf("Cyprias", "sarhatabaot") | ||
website = "https://github.com/Cyprias/ChunkSpawnerLimiter" | ||
description = "Limit entities in chunks." | ||
load = BukkitPluginDescription.PluginLoadOrder.POSTWORLD | ||
prefix = "CSL" | ||
} | ||
|
||
tasks { | ||
build { | ||
dependsOn(shadowJar) | ||
} | ||
|
||
shadowJar { | ||
minimize() | ||
|
||
exclude("META-INF/**") | ||
|
||
archiveFileName.set("chunkspawnerlimiter-${project.version}.jar") | ||
archiveClassifier.set("shadow") | ||
|
||
relocate("de.tr7zw.changeme.nbtapi", "com.cyprias.chunkspawnerlimiter.libs.nbt") | ||
relocate("co.aikar.commands", "com.cyprias.chunkspawnerlimiter.libs.acf") | ||
relocate("co.aikar.locales", "com.cyprias.chunkspawnerlimiter.libs.locales") | ||
} | ||
|
||
compileJava { | ||
options.compilerArgs.add("-parameters") | ||
options.isFork = true | ||
options.encoding = "UTF-8" | ||
} | ||
} | ||
|
||
java { | ||
toolchain { | ||
languageVersion.set(JavaLanguageVersion.of(8)) | ||
vendor.set(JvmVendorSpec.ADOPTIUM) | ||
} | ||
} |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
distributionBase=GRADLE_USER_HOME | ||
distributionPath=wrapper/dists | ||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.7-bin.zip | ||
networkTimeout=10000 | ||
validateDistributionUrl=true | ||
zipStoreBase=GRADLE_USER_HOME | ||
zipStorePath=wrapper/dists |
Oops, something went wrong.