From afb0909442a551bb1de59ccbcc6c3a7c4a15a3ed Mon Sep 17 00:00:00 2001 From: My-Name-Is-Jeff <37018278+My-Name-Is-Jeff@users.noreply.github.com> Date: Wed, 20 Mar 2024 00:02:20 -0400 Subject: [PATCH] build: Setup for JitPack --- .github/workflows/autojitpack.yml | 19 +++++++++++++++++++ build.gradle.kts | 1 + jitpack.yml | 9 +++++++++ 3 files changed, 29 insertions(+) create mode 100644 .github/workflows/autojitpack.yml create mode 100644 jitpack.yml diff --git a/.github/workflows/autojitpack.yml b/.github/workflows/autojitpack.yml new file mode 100644 index 0000000..1eb26af --- /dev/null +++ b/.github/workflows/autojitpack.yml @@ -0,0 +1,19 @@ +name: AutoJitpack + +on: + push: + branches: ["master"] + +jobs: + build: + runs-on: ubuntu-latest + steps: + - uses: web3j/substr-action@e448c146620c370c177a13787abc1d21712a1440 + id: jitpackhash + with: + value: ${{ github.sha }} + start: 0 + length: 10 + - uses: badasintended/autojitpack@07e74255c2fe5f3353477da9ee7b5767a87d390c + with: + version: ${{ steps.jitpackhash.outputs.result }} \ No newline at end of file diff --git a/build.gradle.kts b/build.gradle.kts index 554130a..df0e0d9 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -7,6 +7,7 @@ plugins { id("org.jetbrains.kotlinx.binary-compatibility-validator") version "0.8.0" id("org.jetbrains.dokka") version "1.6.10" apply false id("gg.essential.defaults") + id("maven-publish") } kotlin.jvmToolchain { diff --git a/jitpack.yml b/jitpack.yml new file mode 100644 index 0000000..950ed39 --- /dev/null +++ b/jitpack.yml @@ -0,0 +1,9 @@ +jdk: + - openjdk16 +before_install: + - sdk update + - sdk install java 16.0.2-tem + - sdk install java 17.0.3-tem + - sdk use java 17.0.3-tem +install: + - ./gradlew publishToMavenLocal \ No newline at end of file