Skip to content

Commit

Permalink
Remove changelog.txt stuff
Browse files Browse the repository at this point in the history
  • Loading branch information
strubium committed May 28, 2024
1 parent 37d6538 commit 26a3d46
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 80 deletions.
67 changes: 13 additions & 54 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@

// For those who want the bleeding edge
buildscript {
repositories {
Expand Down Expand Up @@ -28,15 +27,15 @@ apply plugin: 'net.minecraftforge.gradle.forge'
apply plugin: 'maven-publish'

repositories {
maven { // The repo from which to get waila
name "Mobius Repo"
url "https://tehnut.info/maven"
maven {
name = "Mobius Repo"
url = "https://tehnut.info/maven"
}
maven { // JEI
url "http://dvs1.progwml6.com/files/maven"
maven {
url = "http://dvs1.progwml6.com/files/maven"
}
maven { // CompatLayer
url "http://maven.k-4u.nl"
maven {
url = "http://maven.k-4u.nl"
}
maven {
name = "sonatype"
Expand All @@ -52,14 +51,14 @@ def ENV = System.getenv()
if (ENV.DRONE_BUILD_NUMBER) {
version += ".n" + ENV.DRONE_BUILD_NUMBER
}
group= "mcjty.theoneprobe" // http://maven.apache.org/guides/mini/guide-naming-conventions.html

group = "mcjty.theoneprobe"
archivesBaseName = "theoneprobe"

if (System.getenv('BUILD_NUMBER') != null) {
version += "-${System.getenv('BUILD_NUMBER')}"
}


sourceCompatibility = 1.8
targetCompatibility = 1.8

Expand All @@ -68,7 +67,6 @@ minecraft {
runDir = "run"
mappings = mcp_mappings
useDepAts = true

}

dependencies {
Expand All @@ -82,21 +80,14 @@ jar {
}
}

processResources
{
// this will ensure that this task is redone when the versions change.
processResources {
inputs.property "version", project.version
inputs.property "mcversion", project.minecraft.version

// replace stuff in mcmod.info, nothing else
from(sourceSets.main.resources.srcDirs) {
include 'mcmod.info'

// replace version and mcversion
expand 'version':project.version, 'mcversion':project.minecraft.version
expand 'version': project.version, 'mcversion': project.minecraft.version
}

// copy everything else, thats not the mcmod.info
from(sourceSets.main.resources.srcDirs) {
exclude 'mcmod.info'
}
Expand All @@ -114,7 +105,6 @@ artifacts {
}

publishing {
tasks.publish.dependsOn 'build'
publications {
mavenJava(MavenPublication) {
from components.java
Expand All @@ -131,38 +121,6 @@ publishing {
}
}
}

String getChangelogText() {
def changelogFile = file('changelog.txt')
String str = ''
int lineCount = 0
boolean done = false
changelogFile.eachLine {
if (done || it == null) {
return
}
if (it.size() > 1) {
def temp = it
if (lineCount == 0) {
temp = "${modname} ${version}"
temp = "<h2>$temp</h2>"
} else if (it.startsWith('-')) {
temp = "&nbsp;&nbsp;&nbsp;$temp"
temp = temp.replaceAll("(\\S+\\/\\S+)#([0-9]+)\\b", "<a href=\"https://github.com/\$1/issues/\$2\">\$0</a>");
temp = temp.replaceAll("#([0-9]+)\\b(?!<\\/a>)", "<a href=\"https://github.com/$github_project/issues/\$1\">\$0</a>");
} else {
temp = "<h4>$temp</h4>"
}
str += "$temp<br/>"
lineCount++
return
} else {
done = true
}
}
return str
}

tasks.curseforge.enabled = project.hasProperty('curseforge_key')

curseforge {
Expand All @@ -172,7 +130,7 @@ curseforge {

project {
id = project.projectId
changelog = System.getenv('CHANGELOG') == null || System.getenv('CHANGELOG').equals('none') ? getChangelogText() : System.getenv('CHANGELOG')

changelogType = 'html'
releaseType = project.curse_type
addGameVersion '1.12.2'
Expand All @@ -185,3 +143,4 @@ curseforge {
}
}
}

22 changes: 0 additions & 22 deletions changelog.txt

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,10 @@ public void addProbeInfo(ProbeMode mode, IProbeInfo probeInfo, EntityPlayer play
int fill = blockState.getValue(integerProperty);
int maxFill = Collections.max(integerProperty.getAllowedValues());

IProbeInfo horizontalPane = probeInfo.horizontal(probeInfo.defaultLayoutStyle().alignment(ElementAlignment.ALIGN_CENTER));

if (fill > 0) {
horizontalPane.item((fill == maxFill) ? WATER_BUCKET : WATTER_BOTTLE);
horizontalPane.text(TextStyleClass.LABEL + ((fill == 1) ? " {*theoneprobe.probe.bottle_indicator*}" : " {*theoneprobe.probe.bottles_indicator*}"));
probeInfo.horizontal(probeInfo.defaultLayoutStyle().alignment(ElementAlignment.ALIGN_CENTER))
.item((fill == maxFill) ? WATER_BUCKET : WATTER_BOTTLE)
.text(TextStyleClass.LABEL + ((fill == 1) ? " {*theoneprobe.probe.bottle_indicator*}" : " {*theoneprobe.probe.bottles_indicator*}"));
} else {
probeInfo.horizontal(probeInfo.defaultLayoutStyle().alignment(ElementAlignment.ALIGN_CENTER))
.item(BUCKET)
Expand Down

0 comments on commit 26a3d46

Please sign in to comment.