diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS new file mode 100644 index 0000000..7d203e7 --- /dev/null +++ b/.github/CODEOWNERS @@ -0,0 +1 @@ +* @Offz diff --git a/.github/workflows/gradle-ci.yml b/.github/workflows/gradle-ci.yml index 6e8b618..ee8c605 100644 --- a/.github/workflows/gradle-ci.yml +++ b/.github/workflows/gradle-ci.yml @@ -4,6 +4,7 @@ on: push: paths-ignore: - '**.md' + - 'CODEOWNERS' jobs: build: @@ -23,8 +24,12 @@ jobs: - name: Grant execute permission for gradlew run: chmod +x gradlew + # We build twice to include generated files lol - name: Build - run: gradle build --stacktrace + run: gradle build + + - name: Build another time :) + run: gradle build - name: Upload build uses: actions/upload-artifact@v1 diff --git a/.github/workflows/publish-packages.yml b/.github/workflows/publish-packages.yml index b64cd49..32b15f6 100644 --- a/.github/workflows/publish-packages.yml +++ b/.github/workflows/publish-packages.yml @@ -6,6 +6,7 @@ on: - master paths-ignore: - '**.md' + - 'CODEOWNERS' jobs: build: @@ -26,8 +27,12 @@ jobs: - name: Grant execute permission for gradlew run: chmod +x gradlew + # We build twice to include generated files lol - name: Run gradle build and publish - run: gradle build publish -PmineinabyssMavenUsername=${{ secrets.MAVEN_PUBLISH_USERNAME }} -PmineinabyssMavenPassword=${{ secrets.MAVEN_PUBLISH_PASSWORD }} + run: gradle build + + - name: Run gradle build and publish + run: gradle publish -PmineinabyssMavenUsername=${{ secrets.MAVEN_PUBLISH_USERNAME }} -PmineinabyssMavenPassword=${{ secrets.MAVEN_PUBLISH_PASSWORD }} - name: Get version from gradle shell: bash @@ -43,6 +48,5 @@ jobs: prerelease: false automatic_release_tag: v${{ steps.extract_version.outputs.version }} files: | - protocolburrito-plugin/build/libs/protocolburrito-plugin*.jar - !*-dev* + protocolburrito-plugin/build/libs/protocolburrito-plugin*[0-9].jar diff --git a/.gitmodules b/.gitmodules deleted file mode 100644 index 46e71b0..0000000 --- a/.gitmodules +++ /dev/null @@ -1,3 +0,0 @@ -[submodule "minecraft-data"] - path = minecraft-data - url = https://github.com/PrismarineJS/minecraft-data.git diff --git a/build.gradle.kts b/build.gradle.kts index fd0c3cd..217c1e2 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -1,3 +1,5 @@ +val serverVersion: String by project + plugins { kotlin("jvm") id("com.mineinabyss.conventions.kotlin") @@ -14,6 +16,8 @@ repositories { allprojects { apply(plugin = "java") + version = rootProject.version + repositories { maven("https://hub.spigotmc.org/nexus/content/repositories/snapshots/") maven("https://repo.dmulloy2.net/nexus/repository/public/")//ProtocolLib @@ -30,12 +34,10 @@ allprojects { } dependencies { - compileOnly("org.spigotmc:spigot-api:1.18.2-R0.1-SNAPSHOT") + compileOnly("org.spigotmc:spigot-api:$serverVersion") api(project(":protocolburrito-api")) - compileOnly(project(":protocolburrito-generator")) } - sourceSets["main"].java.srcDir(file("$rootDir/protocolburrito-generator/build/generated/burrito/main")) tasks { @@ -43,6 +45,7 @@ tasks { dependsOn(reobfJar) dependsOn(project(":protocolburrito-plugin").tasks.build) } + shadowJar { archiveClassifier.set("") } diff --git a/protocolburrito-plugin/build.gradle.kts b/protocolburrito-plugin/build.gradle.kts index 3293792..34f7afb 100644 --- a/protocolburrito-plugin/build.gradle.kts +++ b/protocolburrito-plugin/build.gradle.kts @@ -9,9 +9,6 @@ plugins { } dependencies { - // MineInAbyss platform -// spigot(libs.kotlin.stdlib) - implementation(project(":")) implementation("com.mineinabyss:idofront:$idofrontVersion") } @@ -22,4 +19,8 @@ tasks { include(dependency("com.mineinabyss:idofront.*:.*")) } } + + assemble { + dependsOn(project(":protocolburrito-generator").tasks.assemble) + } }