Skip to content

Commit 30c9956

Browse files
committed
Merge 1.19.2 into 1.19.4
2 parents 152e795 + 7cc579f commit 30c9956

File tree

2 files changed

+16
-2
lines changed

2 files changed

+16
-2
lines changed

build.gradle

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,11 @@ allprojects {
3939
def dirtyMarker = grgit.status().clean ? "" : ".dirty"
4040
def commitHashMarker = details.commitDistance > 0 ? ("." + details.gitHash) : ""
4141
def preMarker = (details.commitDistance > 0 || !details.isCleanTag) ? ("-beta." + details.commitDistance) : ""
42+
if(preMarker.length() > 0) {
43+
// bump to next patch release
44+
def versionParts = baseVersion.tokenize(".")
45+
baseVersion = "${versionParts[0]}.${versionParts[1]}.${versionParts[2].toInteger() + 1}"
46+
}
4247
def versionString = "${baseVersion}${preMarker}+mc${minecraft_version}${commitHashMarker}${dirtyMarker}"
4348
version = versionString
4449
archivesBaseName = rootProject.archives_base_name + '-' + project.name
@@ -239,3 +244,5 @@ configure(subprojects.findAll {it.name == "forge" || it.name == "fabric"}) {
239244
publishToModSites.dependsOn(tasks.curseforge)
240245
}
241246
}
247+
248+
println "ModernFix: " + version

scripts/autorelease.sh

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,12 +21,19 @@ cd mfix
2121
# gather version list
2222
readarray -t all_versions < <(git ls-remote --heads origin | awk '{print $2}' | sed 's:.*/::' | sort -V)
2323

24+
last_released_version=""
2425
do_release() {
2526
echo "will now make release for $1"
2627
git checkout $1 &>/dev/null || git checkout -b $1 &>/dev/null
27-
echo "we think the current tag is $(git describe --tags --abbrev=0)"
28+
current_tag=$(git describe --tags --abbrev=0)
29+
echo "we think the current tag is $current_tag"
2830
echo "the current commit head is $(git rev-parse HEAD)"
29-
read -p "new tag name: " tag_name
31+
old_version_specifier=$(echo $current_tag | awk -F+ '{print $2}')
32+
read -e -p "new tag name (${old_version_specifier}): " -i "${last_released_version}" tag_name
33+
if [[ $tag_name != *"+"* ]]; then
34+
tag_name=${tag_name}+${old_version_specifier}
35+
fi
36+
last_released_version=$(echo $tag_name | awk -F+ '{print $1}')
3037
git tag -a $tag_name -m "$tag_name"
3138
git push --tags
3239
gh release create $tag_name --target $1 --title "$tag_name" --notes ""

0 commit comments

Comments
 (0)