Skip to content

Commit

Permalink
New version beta
Browse files Browse the repository at this point in the history
+ Moved to Minecraft 1.21
+ Moved to ac core 1.5.11-beta1
  • Loading branch information
EnricoMessall committed Sep 17, 2024
1 parent 44e0d8d commit eb2ee46
Show file tree
Hide file tree
Showing 8 changed files with 62 additions and 76 deletions.
28 changes: 0 additions & 28 deletions .github/workflows/beta.yml

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -14,21 +14,21 @@ jobs:
- uses: actions/checkout@main
- name: Fetch tags
run: git fetch --tags
- name: Set up JDK 17
- name: Set up JDK 21
uses: actions/setup-java@v1
with:
java-version: 17
java-version: 21
- name: Upload to websites
run: ./gradlew publishThirdParty --stacktrace -PlastTag="v${{ github.event.inputs.previousVersion }}" -PcurrentTag="v${{ github.event.inputs.version }}"
if: |
!contains(github.event.head_commit.message, '[ci skip]') && !contains(github.event.pull_request.title, '[ci skip]')
env:
modrinth_token: ${{ secrets.MODRINTH_TOKEN }}
curseforge_token: ${{ secrets.CURSEFORGE_TOKEN }}
github_token: ${{ secrets.GH_API_KEY }}
discord_release_webhook: ${{ secrets.DISCORD_RELEASE_WEBHOOK }}
USERNAME: ${{ secrets.GH_USERNAME }}
TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Capture build artifacts
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v4
with:
name: Artifacts
path: build/libs/
51 changes: 33 additions & 18 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,40 +1,57 @@
plugins {
id 'fabric-loom' version '1.0-SNAPSHOT'
id 'fabric-loom' version '1.7.2'
id 'maven-publish'
id "io.freefair.lombok" version "6.0.0-m2"
id "io.freefair.lombok" version "8.10"
}

sourceCompatibility = JavaVersion.VERSION_16
targetCompatibility = JavaVersion.VERSION_16
java {
toolchain {
languageVersion = JavaLanguageVersion.of(21)
}
}

apply from: 'https://gist.githubusercontent.com/EnricoMessall/fb5de26a0ac26840060fd1ef45c32a5f/raw/cba2886a0fc2c95b24fc093684b4e6bfeafbd5ba/publish.gradle'

sourceCompatibility = JavaVersion.VERSION_21
targetCompatibility = JavaVersion.VERSION_21

archivesBaseName = project.archives_base_name
version = "${project.minecraft_version}-${project.mod_version}"
group = project.maven_group

apply from: 'https://raw.githubusercontent.com/DarkKronicle/GradleScripts/main/gradle/publish.gradle'

repositories {
mavenCentral()
mavenLocal() // only used to build the mod locally
maven { url 'https://masa.dy.fi/maven' }
maven { url 'https://jitpack.io' }

maven {
url = uri("https://maven.pkg.github.com/Arematics/AdvancedChatCore")
credentials {
username = project.findProperty("gpr.user") ?: System.getenv("USERNAME")
password = project.findProperty("gpr.key") ?: System.getenv("TOKEN")
}
}
}

dependencies {
minecraft "com.mojang:minecraft:${project.minecraft_version}"
mappings "net.fabricmc:yarn:${project.yarn_mappings}:v2"
modImplementation "net.fabricmc:fabric-loader:${project.loader_version}"
modImplementation "net.fabricmc.fabric-api:fabric-api:${project.fabric_api_version}"
modImplementation "fi.dy.masa.malilib:malilib-fabric-1.20.2:${project.malilib_version}"
//modImplementation "com.github.DarkKronicle:AdvancedChatCore:${project.advancedchat_version}"
modImplementation "io.github.darkkronicle:AdvancedChatCore:1.20.4-1.5.10" // only used to build the mod locally
modImplementation "fi.dy.masa.malilib:malilib-fabric-1.21:${project.malilib_version}"
modImplementation "com.arematics:advancedchatcore:${project.advancedchat_version}"

implementation "com.github.DarkKronicle.Konstruct:addons:${project.konstruct_version}"
implementation "com.github.DarkKronicle.Konstruct:core:${project.konstruct_version}"

implementation 'org.openjdk.nashorn:nashorn-core:15.3'
implementation 'org.javadelight:delight-nashorn-sandbox:0.2.5'

include 'org.openjdk.nashorn:nashorn-core:15.3'
include 'org.javadelight:delight-nashorn-sandbox:0.2.5'
include group: 'org.webjars.bower', name: 'js-beautify', version: '1.9.0'
include "com.github.DarkKronicle.Konstruct:addons:${project.konstruct_version}"
include "com.github.DarkKronicle.Konstruct:core:${project.konstruct_version}"

}

Expand All @@ -48,12 +65,11 @@ processResources {

tasks.withType(JavaCompile).configureEach {
it.options.encoding = "UTF-8"
it.options.release = 16
it.options.release = 21
}

task sourcesJar(type: Jar, dependsOn: classes) {
classifier = "sources"
from sourceSets.main.allSource
java {
withSourcesJar()
}

jar {
Expand All @@ -74,9 +90,8 @@ publishing {
}
}

// select the repositories you want to publish to
// See https://docs.gradle.org/current/userguide/publishing_maven.html for information on how to set up publishing.
repositories {
// uncomment to publish to the local maven
// mavenLocal()

}
}
}
27 changes: 12 additions & 15 deletions gradle.properties
Original file line number Diff line number Diff line change
@@ -1,28 +1,25 @@
minecraft_version=1.20.4
yarn_mappings=1.20.4+build.3
loader_version=0.15.3
fabric_api_version=0.92.0+1.20.4
minecraft_version=1.21
yarn_mappings=1.21+build.9
loader_version=0.15.11
fabric_api_version=0.100.1+1.21
konstruct_version=2.0.3-build1

mod_version=1.2.8
maven_group=io.github.darkkronicle
mod_version=1.2.9-beta1
maven_group=com.arematics
archives_base_name=AdvancedChatFilters

malilib_version = 0.17.0
malilib_version = 0.20.0
org.gradle.jvmargs=-Xmx1G
advancedchat_version=v1.5.10
advancedchat_version=1.21-1.5.11-beta1
owo_version=2.0.0

# publishing
curseforge_slug=advancedchatfilters
curseforge_id=539122

modrinth_slug=advancedchatfilters
modrinth_id=c6fx2vMe
modrinth_slug=advancedchatfilters-next
modrinth_id=wNgI7mfM

# default_release_type can be stable, beta, or alpha
default_release_type=stable
project_name=AdvancedChatFilters
project_url=https://modrinth.com/mod/advancedchatfilters
project_url=https://modrinth.com/mod/advancedchatfilters-next
project_logo=https://raw.githubusercontent.com/DarkKronicle/AdvancedChatFilters/main/src/main/resources/assets/advancedchatfilters/icon.png
project_color=0x134bff
changelog_hide_unimportant_commits=true
Expand Down
2 changes: 1 addition & 1 deletion gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-7.2-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.8-bin.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ public IntRange getArgumentCount() {
}

public static SoundEvent getEvent(String name) {
return SoundEvent.of(new Identifier(name));
return SoundEvent.of(Identifier.of(name));
}

/* How the filter notifies the client of a found string.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ public TextBuilder setStrikethrough(boolean strikethrough) {
*/
public TextBuilder setFont(String namespace, String name) {
// Dunno if this will do anything or how it works
applyStyle(style -> style.withFont(new Identifier(namespace, name)));
applyStyle(style -> style.withFont(Identifier.of(namespace, name)));
return this;
}

Expand Down
16 changes: 9 additions & 7 deletions src/main/resources/fabric.mod.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,13 @@
"name": "AdvancedChatFilters",
"description": "Filters for AdvancedChat",
"authors": [
"DarkKronicle"
"DarkKronicle",
"EnricoMessall"
],
"contact": {
"sources": "https://github.com/DarkKronicle/AdvancedChat",
"discord": "https://discord.gg/WnaE3uZxDA"
"homepage": "https://arematics.com",
"sources": "https://github.com/Arematics/AdvancedChatFilters",
"issues": "https://github.com/Arematics/AdvancedChatFilters/issues"
},
"license": "MPL-v2",
"icon": "assets/advancedchatfilters/icon.png",
Expand All @@ -20,11 +22,11 @@
]
},
"depends": {
"fabricloader": ">=0.14.18",
"fabricloader": ">=0.15.11",
"fabric": "*",
"minecraft": ">=1.20",
"malilib": ">=0.16.0",
"advancedchatcore": ">=1.5.10-1.19"
"minecraft": ">=1.21",
"malilib": ">=0.20.0",
"advancedchatcore": ">=1.5.11-1.21"
},
"custom": {
"acmodule": true,
Expand Down

0 comments on commit eb2ee46

Please sign in to comment.