Skip to content
This repository has been archived by the owner on Mar 20, 2023. It is now read-only.

Commit

Permalink
grgit abandoned, indra time.
Browse files Browse the repository at this point in the history
  • Loading branch information
i509VCB committed Apr 28, 2021
1 parent b76040a commit 7763418
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ plugins {
id 'java' // for jd gen
id 'org.cadixdev.licenser' version '0.5.1'
id 'net.fabricmc.filament' version '0.2.0'
id "org.ajoberstar.grgit" version "4.1.0"
id "net.kyori.indra.git" version "2.0.0"
}

def minecraft_version = "21w17a"
Expand All @@ -37,7 +37,12 @@ def yarnVersion = "${minecraft_version}+build.$build_number"
version = yarnVersion

if (ENV.VALIDATE_BRANCH) {
def branch = grgit.branch.current().name
def branch = indraGit.branchName()

if (branch == null) {
throw new IllegalStateException("No repository found? You may have a detached head?");
}

if (minecraft_version != branch) {
throw new IllegalStateException("Branch name (${branch}) does not match the mc version (${minecraft_version})")
}
Expand Down

0 comments on commit 7763418

Please sign in to comment.