diff --git a/.github/workflows/publish-release.yml b/.github/workflows/publish-release.yml index 9b704889..c3a08250 100644 --- a/.github/workflows/publish-release.yml +++ b/.github/workflows/publish-release.yml @@ -28,9 +28,12 @@ jobs: # we can get the release name. run: | NEW_VERSION=$(echo "${GITHUB_REF}" | cut -d "/" -f3) + NEW_VERSION_TRUNC=$(echo "${NEW_VERSION}" | grep -oP 'mc[0-9]+\.[0-9]+(?:\.[0-9]+)?-v\K[0-9\.a-zA-Z]+') echo "New version: ${NEW_VERSION}" + echo "Truncated version: ${NEW_VERSION_TRUNC}" + [ -z "${NEW_VERSION_TRUNC}" ] && exit 1 echo "Github username: ${GITHUB_ACTOR}" echo "maven.edtoaster.ca username: ${EDTOASTER_MAVEN_USER}" ./gradlew wrapper ./gradlew runData - ./gradlew -Pversion=${NEW_VERSION} publish \ No newline at end of file + ./gradlew -Pmod_version=${NEW_VERSION_TRUNC} publish \ No newline at end of file diff --git a/.github/workflows/verify-pr.yml b/.github/workflows/verify-pr.yml new file mode 100644 index 00000000..a5f9f5b6 --- /dev/null +++ b/.github/workflows/verify-pr.yml @@ -0,0 +1,24 @@ +name: Verify PR + +on: + push: + pull_request: + workflow_dispatch: + +jobs: + verify-pr: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v2 + - name: Set up JDK 17 + uses: actions/setup-java@v2 + with: + java-version: '17' + distribution: 'adopt' + + - name: Verify artifact + run: | + ./gradlew wrapper + ./gradlew runData + ./gradlew build \ No newline at end of file diff --git a/build.gradle b/build.gradle index f67dd057..3fa7b1b7 100644 --- a/build.gradle +++ b/build.gradle @@ -252,11 +252,10 @@ repositories { name = "Progwml6 maven" url = "https://dvs1.progwml6.com/files/maven/" } + maven { - // location of a maven mirror for JEI files, as a fallback - name = "ModMaven" - url = "https://modmaven.dev" + // location of patchouli + name = "Jared" + url 'https://maven.blamejared.com' } - maven { url 'https://maven.blamejared.com' } - } \ No newline at end of file diff --git a/gradle.properties b/gradle.properties index ac746531..bf777ffc 100644 --- a/gradle.properties +++ b/gradle.properties @@ -4,7 +4,7 @@ org.gradle.jvmargs = -Xmx3G org.gradle.daemon = false # Core properties -mod_version = 1.1.4 +mod_version = 1.1.0dev mod_group = dev.murad.littlelogistics mod_id = littlelogistics mod_title = Little Logistics diff --git a/src/main/java/dev/murad/shipping/entity/custom/tug/AbstractTugEntity.java b/src/main/java/dev/murad/shipping/entity/custom/tug/AbstractTugEntity.java index ff087c9e..ecfedd1c 100644 --- a/src/main/java/dev/murad/shipping/entity/custom/tug/AbstractTugEntity.java +++ b/src/main/java/dev/murad/shipping/entity/custom/tug/AbstractTugEntity.java @@ -443,7 +443,9 @@ protected void defineSynchedData() { public void setPath(TugRoute path) { - this.nextStop = 0; + if (!this.path.isEmpty()){ + this.nextStop = 0; + } this.path = path; }