From bcfd6347738d4c0e2157244de98d2f1b57cb24fc Mon Sep 17 00:00:00 2001 From: tiagodinis33 <36360774+tiagodinis33@users.noreply.github.com> Date: Thu, 19 Aug 2021 23:06:25 +0100 Subject: [PATCH 01/13] compressed all build-java* into 1 using strategy.matrix --- .github/workflows/unofficial-builds.yml | 53 ++++--------------------- 1 file changed, 8 insertions(+), 45 deletions(-) diff --git a/.github/workflows/unofficial-builds.yml b/.github/workflows/unofficial-builds.yml index 55d7d1e8..d8bfccde 100644 --- a/.github/workflows/unofficial-builds.yml +++ b/.github/workflows/unofficial-builds.yml @@ -6,58 +6,21 @@ name: Unofficial Builds on: workflow_dispatch jobs: - build-java16: + build: runs-on: ubuntu-latest - - steps: - - uses: actions/checkout@v2 - - name: Set up JDK 16 - uses: actions/setup-java@v2 - with: - java-version: '16' - distribution: 'adopt' - - name: Grant execute permission for gradlew - run: chmod +x gradlew - - name: Tests with Gradle - run: ./gradlew test - - name: Build with Gradle - run: ./gradlew shadowJar - if: always() - with: - files: build/test-results/**/*.xml - - build-java11: - - runs-on: ubuntu-latest - - steps: - - uses: actions/checkout@v2 - - name: Set up JDK 11 - uses: actions/setup-java@v2 - with: - java-version: '11' - distribution: 'adopt' - - name: Grant execute permission for gradlew - run: chmod +x gradlew - - name: Tests with Gradle - run: ./gradlew test - - name: Build with Gradle - run: ./gradlew shadowJar - if: always() - with: - files: build/test-results/**/*.xml - - build-java8: - - runs-on: ubuntu-latest - + strategy: + matrix: + java-version: + - '8' + - '11' + - '16' steps: - uses: actions/checkout@v2 - name: Set up JDK 8 uses: actions/setup-java@v2 with: - java-version: '8' + java-version: ${{ matrix.java-version }} distribution: 'adopt' - name: Grant execute permission for gradlew run: chmod +x gradlew From 1438600cbbff1d7cc8237852b022d75e7cd470e9 Mon Sep 17 00:00:00 2001 From: tiagodinis33 <36360774+tiagodinis33@users.noreply.github.com> Date: Thu, 19 Aug 2021 23:10:05 +0100 Subject: [PATCH 02/13] Update unofficial-builds.yml --- .github/workflows/unofficial-builds.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/unofficial-builds.yml b/.github/workflows/unofficial-builds.yml index d8bfccde..b1654852 100644 --- a/.github/workflows/unofficial-builds.yml +++ b/.github/workflows/unofficial-builds.yml @@ -17,7 +17,7 @@ jobs: - '16' steps: - uses: actions/checkout@v2 - - name: Set up JDK 8 + - name: Set up JDK ${{ matrix.java-version }} uses: actions/setup-java@v2 with: java-version: ${{ matrix.java-version }} From 756413507a36056a71d54e529ce760b914943c26 Mon Sep 17 00:00:00 2001 From: tiagodinis33 <36360774+tiagodinis33@users.noreply.github.com> Date: Sat, 21 Aug 2021 19:21:45 +0100 Subject: [PATCH 03/13] Update unofficial-builds.yml --- .github/workflows/unofficial-builds.yml | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/.github/workflows/unofficial-builds.yml b/.github/workflows/unofficial-builds.yml index b1654852..c516a424 100644 --- a/.github/workflows/unofficial-builds.yml +++ b/.github/workflows/unofficial-builds.yml @@ -26,12 +26,18 @@ jobs: run: chmod +x gradlew - name: Tests with Gradle run: ./gradlew test + - name: Build with Gradle run: ./gradlew shadowJar + + - name: Publish Test Report + uses: mikepenz/action-junit-report@v1 if: always() with: - files: build/test-results/**/*.xml + report_paths: '**/build/test-results/test/TEST-*.xml' + github_token: ${{ github.token }} - name: Upload Artifact + if: matrix.java-version == '8' uses: actions/upload-artifact@v2.2.2 with: name: Builds From bcf97c181c94b79e820123feb83dcc8fc34eb357 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 27 Aug 2021 06:10:00 +0000 Subject: [PATCH 04/13] Bump jackson-databind from 2.12.4 to 2.12.5 Bumps [jackson-databind](https://github.com/FasterXML/jackson) from 2.12.4 to 2.12.5. - [Release notes](https://github.com/FasterXML/jackson/releases) - [Commits](https://github.com/FasterXML/jackson/commits) --- updated-dependencies: - dependency-name: com.fasterxml.jackson.core:jackson-databind dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle b/build.gradle index 114f8151..f0647e7c 100644 --- a/build.gradle +++ b/build.gradle @@ -91,7 +91,7 @@ dependencies { compileOnly('com.github.Realizedd:TokenManager:3.2.4') { transitive = false } // Other libraries implementation 'com.github.mkremins:fanciful:18dc039f5b' - slim 'com.fasterxml.jackson.core:jackson-databind:2.12.4' + slim 'com.fasterxml.jackson.core:jackson-databind:2.12.5' slim 'com.fasterxml.jackson.dataformat:jackson-dataformat-yaml:2.12.4' implementation 'org.apache.maven:maven-artifact:3.8.2' implementation 'org.bstats:bstats-bukkit:2.2.1' From abedf1b2c56fda5c3574de14a509ce09b455c22d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 30 Aug 2021 06:12:40 +0000 Subject: [PATCH 05/13] Bump sqlite-jdbc from 3.36.0.1 to 3.36.0.3 Bumps [sqlite-jdbc](https://github.com/xerial/sqlite-jdbc) from 3.36.0.1 to 3.36.0.3. - [Release notes](https://github.com/xerial/sqlite-jdbc/releases) - [Changelog](https://github.com/xerial/sqlite-jdbc/blob/master/CHANGELOG) - [Commits](https://github.com/xerial/sqlite-jdbc/compare/3.36.0.1...3.36.0.3) --- updated-dependencies: - dependency-name: org.xerial:sqlite-jdbc dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle b/build.gradle index 114f8151..b77233e4 100644 --- a/build.gradle +++ b/build.gradle @@ -77,7 +77,7 @@ dependencies { slim 'org.mongodb:mongodb-driver-sync:4.3.1' slim 'com.zaxxer:HikariCP:4.0.3' slim 'com.h2database:h2:1.4.200' - slim 'org.xerial:sqlite-jdbc:3.36.0.1' + slim 'org.xerial:sqlite-jdbc:3.36.0.3' slim 'org.mariadb.jdbc:mariadb-java-client:2.7.4' slim 'mysql:mysql-connector-java:8.0.26' implementation 'org.spongepowered:configurate-core:4.1.2' From 1044ffaa03808940f9e11858efef74697f6d5dcc Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 8 Sep 2021 06:11:13 +0000 Subject: [PATCH 06/13] Bump mongodb-driver-sync from 4.3.1 to 4.3.2 Bumps [mongodb-driver-sync](https://github.com/mongodb/mongo-java-driver) from 4.3.1 to 4.3.2. - [Release notes](https://github.com/mongodb/mongo-java-driver/releases) - [Commits](https://github.com/mongodb/mongo-java-driver/compare/r4.3.1...r4.3.2) --- updated-dependencies: - dependency-name: org.mongodb:mongodb-driver-sync dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle b/build.gradle index 114f8151..d6193f18 100644 --- a/build.gradle +++ b/build.gradle @@ -74,7 +74,7 @@ dependencies { // Spigot compileOnly 'org.spigotmc:spigot-api:1.17.1-R0.1-SNAPSHOT' // Storage Methods - slim 'org.mongodb:mongodb-driver-sync:4.3.1' + slim 'org.mongodb:mongodb-driver-sync:4.3.2' slim 'com.zaxxer:HikariCP:4.0.3' slim 'com.h2database:h2:1.4.200' slim 'org.xerial:sqlite-jdbc:3.36.0.1' From 912d14fd8edef9867638545e37459fa00fdd946b Mon Sep 17 00:00:00 2001 From: Picono435 <57836766+Picono435@users.noreply.github.com> Date: Wed, 8 Sep 2021 12:39:35 +0100 Subject: [PATCH 07/13] Replaced lastest with latest --- .../java/com/gmail/picono435/picojobs/PicoJobsPlugin.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/java/com/gmail/picono435/picojobs/PicoJobsPlugin.java b/src/main/java/com/gmail/picono435/picojobs/PicoJobsPlugin.java index 446d1774..ed4e65a0 100644 --- a/src/main/java/com/gmail/picono435/picojobs/PicoJobsPlugin.java +++ b/src/main/java/com/gmail/picono435/picojobs/PicoJobsPlugin.java @@ -370,13 +370,13 @@ public void run() { } else { new BukkitRunnable() { public void run() { - sendConsoleMessage(Level.INFO, "You are using the lastest version of the plugin."); + sendConsoleMessage(Level.INFO, "You are using the latest version of the plugin."); return; } }.runTaskLater(this, 40L); } } catch (Exception e) { - sendConsoleMessage(Level.WARNING, "Could not get the lastest version."); + sendConsoleMessage(Level.WARNING, "Could not get the latest version."); e.printStackTrace(); return; } From fc1a39cbb3137cb9c43e0b10c44eb49f3eeabb5f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 8 Sep 2021 11:42:52 +0000 Subject: [PATCH 08/13] Bump jackson-dataformat-yaml from 2.12.4 to 2.12.5 Bumps [jackson-dataformat-yaml](https://github.com/FasterXML/jackson-dataformats-text) from 2.12.4 to 2.12.5. - [Release notes](https://github.com/FasterXML/jackson-dataformats-text/releases) - [Commits](https://github.com/FasterXML/jackson-dataformats-text/compare/jackson-dataformats-text-2.12.4...jackson-dataformats-text-2.12.5) --- updated-dependencies: - dependency-name: com.fasterxml.jackson.dataformat:jackson-dataformat-yaml dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle b/build.gradle index 2ed8ca96..ce44150a 100644 --- a/build.gradle +++ b/build.gradle @@ -92,7 +92,7 @@ dependencies { // Other libraries implementation 'com.github.mkremins:fanciful:18dc039f5b' slim 'com.fasterxml.jackson.core:jackson-databind:2.12.5' - slim 'com.fasterxml.jackson.dataformat:jackson-dataformat-yaml:2.12.4' + slim 'com.fasterxml.jackson.dataformat:jackson-dataformat-yaml:2.12.5' implementation 'org.apache.maven:maven-artifact:3.8.2' implementation 'org.bstats:bstats-bukkit:2.2.1' slim 'org.slf4j:slf4j-simple:1.7.32' From 03c326fc40938cca448b4d0ed10907584cb6e804 Mon Sep 17 00:00:00 2001 From: Picono435 <57836766+Picono435@users.noreply.github.com> Date: Wed, 8 Sep 2021 12:55:59 +0100 Subject: [PATCH 09/13] Updated gradle wrapper to 7.2 --- build.gradle | 8 ++++++++ gradle/wrapper/gradle-wrapper.properties | 2 +- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/build.gradle b/build.gradle index ce44150a..96e13c81 100644 --- a/build.gradle +++ b/build.gradle @@ -43,6 +43,14 @@ repositories { url = 'https://hub.spigotmc.org/nexus/content/repositories/snapshots/' } + maven { + url = 'https://oss.sonatype.org/content/repositories/snapshots' + } + + maven { + url = 'https://oss.sonatype.org/content/repositories/central' + } + maven { url = 'https://repo.citizensnpcs.co/' } diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index 69a97150..ffed3a25 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,5 +1,5 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-7.1-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-7.2-bin.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists From cf1b2d043571ab2ecf2a419473b3f233f54e93f9 Mon Sep 17 00:00:00 2001 From: Picono435 <57836766+Picono435@users.noreply.github.com> Date: Wed, 8 Sep 2021 13:37:35 +0100 Subject: [PATCH 10/13] Relocated all dependencies so no conflicts happen --- build.gradle | 26 +++++++++++++++++++++----- 1 file changed, 21 insertions(+), 5 deletions(-) diff --git a/build.gradle b/build.gradle index 96e13c81..3df75027 100644 --- a/build.gradle +++ b/build.gradle @@ -79,6 +79,8 @@ repositories { } dependencies { + // Slimjar + implementation slimjar("1.2.5") // Spigot compileOnly 'org.spigotmc:spigot-api:1.17.1-R0.1-SNAPSHOT' // Storage Methods @@ -112,16 +114,26 @@ dependencies { testCompileOnly('com.github.MilkBowl:VaultAPI:1.7') { transitive = false } testCompileOnly('org.black_ixx:playerpoints:3.0.3') { transitive = false } testCompileOnly('com.github.Realizedd:TokenManager:3.2.4') { transitive = false } - implementation slimjar("1.2.5") } -test { - useJUnitPlatform() +slimJar { + relocate 'org.mongodb', 'com.gmail.picono435.picojobs.libs.mongodb' + relocate 'com.zaxxer', 'com.gmail.picono435.picojobs.libs.zaxxer' + relocate 'com.h2database', 'com.gmail.picono435.picojobs.libs.h2database' + relocate 'org.xerial', 'com.gmail.picono435.picojobs.libs.xerial' + relocate 'org.mariadb.jbdc', 'com.gmail.picono435.picojobs.libs.mariadb' + relocate 'mysql', 'com.gmail.picono435.picojobs.libs.mysql' + relocate 'com.fasterxml.jackson', 'com.gmail.picono435.picojobs.libs.jackson' + relocate 'org.slf4j', 'com.gmail.picono435.picojobs.libs.slf4j' } shadowJar { - relocate 'org.bstats', 'com.gmail.picono435.picojobs' - archiveClassifier = '' + relocate 'org.bstats', 'com.gmail.picono435.picojobs.metrics' + relocate 'org.apache', 'com.gmail.picono435.picojobs.libs.apache' + relocate 'org.spongepowered', 'com.gmail.picono435.picojobs.libs.spongepowered' + relocate 'com.github.mkremins', 'com.gmail.picono435.picojobs.libs.mkremins' + relocate 'io.github.slimjar', 'com.gmail.picono435.picojobs.libs.slimjar' + archiveClassifier = '' } processResources { @@ -132,6 +144,10 @@ processResources { ] } +test { + useJUnitPlatform() +} + rootProject.tasks.named("processResources") { duplicatesStrategy = 'include' } From 9a400dc6eeb8415239904dac02805ab51ff1f9cf Mon Sep 17 00:00:00 2001 From: Picono435 <57836766+Picono435@users.noreply.github.com> Date: Wed, 8 Sep 2021 13:54:51 +0100 Subject: [PATCH 11/13] Modified GitHub actions for more compatibility --- .github/workflows/dev-builds.yml | 107 ++++++++---------------- .github/workflows/stable-build.yml | 3 - .github/workflows/unofficial-builds.yml | 44 ---------- 3 files changed, 33 insertions(+), 121 deletions(-) delete mode 100644 .github/workflows/unofficial-builds.yml diff --git a/.github/workflows/dev-builds.yml b/.github/workflows/dev-builds.yml index ea28821b..f8700524 100644 --- a/.github/workflows/dev-builds.yml +++ b/.github/workflows/dev-builds.yml @@ -1,6 +1,3 @@ -# This workflow will build a Java project with Gradle -# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-gradle - name: Development Builds on: @@ -9,76 +6,38 @@ on: - translations jobs: - build-java16: - - runs-on: ubuntu-latest - - steps: - - uses: actions/checkout@v2 - - name: Set up JDK 16 - uses: actions/setup-java@v2 - with: - java-version: '16' - distribution: 'adopt' - - name: Grant execute permission for gradlew - run: chmod +x gradlew - - name: Tests with Gradle - run: ./gradlew test - - name: Build with Gradle - run: ./gradlew shadowJar - - name: Publish Unit Test Results - uses: EnricoMi/publish-unit-test-result-action@v1 - if: always() - with: - files: build/test-results/**/*.xml - - build-java11: - + build: runs-on: ubuntu-latest - - steps: - - uses: actions/checkout@v2 - - name: Set up JDK 11 - uses: actions/setup-java@v2 - with: - java-version: '11' - distribution: 'adopt' - - name: Grant execute permission for gradlew - run: chmod +x gradlew - - name: Tests with Gradle - run: ./gradlew test - - name: Build with Gradle - run: ./gradlew shadowJar - - name: Publish Unit Test Results - uses: EnricoMi/publish-unit-test-result-action@v1 - if: always() - with: - files: build/test-results/**/*.xml - - build-java8: - - runs-on: ubuntu-latest - + strategy: + matrix: + java-version: + - '8' + - '11' + - '16' steps: - - uses: actions/checkout@v2 - - name: Set up JDK 8 - uses: actions/setup-java@v2 - with: - java-version: '8' - distribution: 'adopt' - - name: Grant execute permission for gradlew - run: chmod +x gradlew - - name: Tests with Gradle - run: ./gradlew test - - name: Build with Gradle - run: ./gradlew shadowJar - - name: Publish Unit Test Results - uses: EnricoMi/publish-unit-test-result-action@v1 - if: always() - with: - files: build/test-results/**/*.xml - - name: Upload Artifact - uses: actions/upload-artifact@v2.2.2 - with: - name: Builds - path: build/libs/*.jar + - uses: actions/checkout@v2 + - name: Set up JDK ${{ matrix.java-version }} + uses: actions/setup-java@v2 + with: + java-version: ${{ matrix.java-version }} + distribution: 'adopt' + - name: Grant execute permission for gradlew + run: chmod +x gradlew + - name: Tests with Gradle + run: ./gradlew test + - name: Build with Gradle + run: ./gradlew shadowJar + - name: Publish Unit Test Results + uses: mikepenz/action-junit-report@v1 + if: > + always() && + github.event.sender.login != 'dependabot[bot]' && + ( github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == github.repository ) + with: + report_paths: '**/build/test-results/test/TEST-*.xml' + - name: Upload Artifact + if: matrix.java-version == '8' + uses: actions/upload-artifact@v2.2.2 + with: + name: Builds + path: build/libs/*.jar diff --git a/.github/workflows/stable-build.yml b/.github/workflows/stable-build.yml index 82b5dfe7..a7b5d024 100644 --- a/.github/workflows/stable-build.yml +++ b/.github/workflows/stable-build.yml @@ -9,11 +9,8 @@ on: workflow_dispatch: jobs: - build: - runs-on: ubuntu-latest - steps: - uses: actions/checkout@v2 - name: Set up JDK 8 diff --git a/.github/workflows/unofficial-builds.yml b/.github/workflows/unofficial-builds.yml deleted file mode 100644 index c516a424..00000000 --- a/.github/workflows/unofficial-builds.yml +++ /dev/null @@ -1,44 +0,0 @@ -# This workflow will build a Java project with Gradle -# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-gradle - -name: Unofficial Builds - -on: workflow_dispatch - -jobs: - build: - - runs-on: ubuntu-latest - strategy: - matrix: - java-version: - - '8' - - '11' - - '16' - steps: - - uses: actions/checkout@v2 - - name: Set up JDK ${{ matrix.java-version }} - uses: actions/setup-java@v2 - with: - java-version: ${{ matrix.java-version }} - distribution: 'adopt' - - name: Grant execute permission for gradlew - run: chmod +x gradlew - - name: Tests with Gradle - run: ./gradlew test - - - name: Build with Gradle - run: ./gradlew shadowJar - - - name: Publish Test Report - uses: mikepenz/action-junit-report@v1 - if: always() - with: - report_paths: '**/build/test-results/test/TEST-*.xml' - github_token: ${{ github.token }} - - name: Upload Artifact - if: matrix.java-version == '8' - uses: actions/upload-artifact@v2.2.2 - with: - name: Builds - path: build/libs/*.jar From b120ca7437938efa850726195231bb39937c1bce Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 13 Sep 2021 06:13:04 +0000 Subject: [PATCH 12/13] Bump junit-jupiter-engine from 5.7.2 to 5.8.0 Bumps [junit-jupiter-engine](https://github.com/junit-team/junit5) from 5.7.2 to 5.8.0. - [Release notes](https://github.com/junit-team/junit5/releases) - [Commits](https://github.com/junit-team/junit5/compare/r5.7.2...r5.8.0) --- updated-dependencies: - dependency-name: org.junit.jupiter:junit-jupiter-engine dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle b/build.gradle index 3df75027..fe5d5db3 100644 --- a/build.gradle +++ b/build.gradle @@ -108,7 +108,7 @@ dependencies { slim 'org.slf4j:slf4j-simple:1.7.32' slim 'org.slf4j:slf4j-api:1.7.32' testImplementation 'com.github.seeseemelk:MockBukkit-v1.16:1.5.0' - testImplementation 'org.junit.jupiter:junit-jupiter-engine:5.7.2' + testImplementation 'org.junit.jupiter:junit-jupiter-engine:5.8.0' testCompileOnly 'org.spigotmc:spigot-api:1.17.1-R0.1-SNAPSHOT' testCompileOnly('me.clip:placeholderapi:2.10.10') { transitive = false } testCompileOnly('com.github.MilkBowl:VaultAPI:1.7') { transitive = false } From 62893c818bf1e0a69dc9500b781133fb10b76b17 Mon Sep 17 00:00:00 2001 From: Picono435 <57836766+Picono435@users.noreply.github.com> Date: Thu, 16 Sep 2021 23:56:06 +0100 Subject: [PATCH 13/13] Bumped version in build.gradle --- build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle b/build.gradle index fe5d5db3..5c3270f1 100644 --- a/build.gradle +++ b/build.gradle @@ -22,7 +22,7 @@ targetCompatibility = '1.8' versioning { releaseMode = { nextTag, lastTag, currentTag, extension -> - "1.0-beta-3c" + "1.0-beta-3d" } as Object }