Skip to content

Commit

Permalink
Bump text version, release 1.0.1
Browse files Browse the repository at this point in the history
  • Loading branch information
zml2008 committed Apr 17, 2020
1 parent 43512a2 commit 42ea3f5
Show file tree
Hide file tree
Showing 5 changed files with 31 additions and 5 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# 1.0.1
- Update to text v3.0.4

# 1.0

- Initial release
20 changes: 19 additions & 1 deletion build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,11 +1,14 @@
import ca.stellardrift.build.apiInclude
import ca.stellardrift.build.implementationInclude
import ca.stellardrift.build.isRelease
import ca.stellardrift.build.kyoriText
import net.fabricmc.loom.task.RemapJarTask
import net.fabricmc.loom.task.RemapSourcesJarTask
import java.time.format.DateTimeFormatter

plugins {
id("ca.stellardrift.opinionated") version "1.0.1"
id("ca.stellardrift.opinionated") version "2.0"
id("ca.stellardrift.opinionated.publish") version "2.0"
id("fabric-loom") version "0.2.7-SNAPSHOT"
}

Expand Down Expand Up @@ -60,6 +63,21 @@ bintray {
pkg.version.released = null
}

val gitInfo by tasks.registering {
doLast {
println("Is release: ${isRelease()}")
val tags = grgit.repository.jgit.tagList().call()
val tagName = tags?.lastOrNull()?.name
println("Tag name: $tagName")
val grgitTag = grgit.resolve.toTag(tagName)
println("JGit tag: ${tags.lastOrNull()}")
println("Grgit tag: $grgitTag")
println("Commit: " + grgit.head())
println("Tag is commit: ${grgitTag.commit == grgit.head()}")
}

}

opinionated {
github("PEXPlugins", "text-adapter-fabric")
mit()
Expand Down
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
versionText=3.0.3
versionText=3.0.4
versionMinecraft=1.15.2
versionMappings=9
versionLoader=0.7.8+build.189
Expand Down
1 change: 1 addition & 0 deletions settings.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@

pluginManagement {
repositories {
mavenLocal()
jcenter()
maven {
name = "Fabric"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -100,15 +100,16 @@ public class MinecraftTextSerializer implements ComponentSerializer<Component, C

/**
* Validates that all members of an enum are present in the given map
* Throws {@link IllegalStateException} if there is a missing value
*
* @param toCheck The map to check
* @param enumClass The enum class to verify coverage
* @param <T> The type of enum
* @throws ExceptionInInitializerError if there is a missing value
*/
private static <T extends Enum<T>> void checkCoverage(Map<T, ?> toCheck, Class<T> enumClass) {
private static <T extends Enum<T>> void checkCoverage(Map<T, ?> toCheck, Class<T> enumClass) throws IllegalStateException {
for (T value : enumClass.getEnumConstants()) {
if (!toCheck.containsKey(value)) {
throw new ExceptionInInitializerError("Unmapped " + enumClass.getSimpleName() + " element '" + value + '!');
throw new IllegalStateException("Unmapped " + enumClass.getSimpleName() + " element '" + value + '!');
}
}
}
Expand Down

0 comments on commit 42ea3f5

Please sign in to comment.