Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
64 changes: 2 additions & 62 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,71 +40,11 @@ jobs:
chmod +x gradlew && ./gradlew lint --no-daemon
echo "::endgroup::"

# =====================================================================
# test — Runtime Validation, Security/Lag Checks & JMC Compiler Checks
# =====================================================================
test:
needs: lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6

- name: Set up JDK 25
uses: actions/setup-java@v5
with:
distribution: temurin
java-version: "25"

- name: Set up Python
uses: actions/setup-python@v6
with:
python-version: "3.12"

# Install Mecha on CI
- name: Install Mecha
run: pip install git+https://github.com/mcbeet/mecha.git

# JMC Verification & Build (Addition 2)
- name: Verify JMC compilation
run: |
echo "::group::Compiling JMC"
pip install jmcfunction --pre
python3 build_jmc.py
echo "::endgroup::"

- name: Upload JMC Build Artifact
uses: actions/upload-artifact@v7
with:
name: jmc-compiled-datapack
path: build/jmc_datapack/
retention-days: 7

# Run Main.java Test Client & Security Scan via Gradle (Addition 1)
- name: Run Main.java Test Client
run: |
chmod +x gradlew
[ "$RUNNER_DEBUG" = "1" ] && echo "::debug::runMainTestClient starting in debug mode"
./gradlew runMainTestClient --no-daemon

# Performance Metrics & Security Reporting (Addition 3)
- name: Performance & Security Report
if: always()
run: |
{
echo "### 🚀 MacroEngine Build & Quality Report"
echo "Verified datapack integrity, compiled JMC assets, and performed live validation."
echo "#### 🛡️ Security & Performance Metrics"
echo "- **JMC Compiler Status:** Passed"
echo "- **Command Wrapper Validation:** Complete (ban, ban_ip, kick, op wrappers online)"
echo "- **Advancement Paths:** Modernized & Safe"
echo "- **Pristine Cleanup:** Successful (all temporary test assets deleted after evaluation)"
} >> "$GITHUB_STEP_SUMMARY"

# =====================================================================
# build — matrix zips (1_20_3, 1_20_5, pre_1_21_4, 1_21_5, 1_21_6, full)
# =====================================================================
build:
needs: test
needs: lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
Expand Down Expand Up @@ -183,7 +123,7 @@ jobs:
git push origin HEAD:${GITHUB_REF#refs/heads/}

archive:
needs: [lint, test, build]
needs: [lint, build]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
Expand Down
58 changes: 2 additions & 56 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -11,24 +11,6 @@ java {
targetCompatibility = JavaVersion.VERSION_25
}

sourceSets {
gametest {
java {
srcDirs = ['src/gametest/java']
}
resources {
srcDirs = ['src/gametest/resources']
}
}
}

afterEvaluate {
configurations {
gametestCompileClasspath.extendsFrom minecraftNamedCompile
gametestRuntimeClasspath.extendsFrom minecraftNamedRuntime
}
}

repositories {
mavenCentral()
maven { url "https://maven.fabricmc.net/" }
Expand All @@ -39,40 +21,11 @@ dependencies {

implementation "net.fabricmc:fabric-loader:0.19.3"
implementation "net.fabricmc.fabric-api:fabric-api:0.155.2+26.2"

gametestImplementation "net.fabricmc:fabric-loader:0.19.3"
gametestImplementation "net.fabricmc.fabric-api:fabric-api:0.155.2+26.2"
}

fabricApi {
configureTests {
createSourceSet = false
modId = 'macroengine-testmod'
}
}

loom {
runs {
gametest {
inherit server
name "Game Test"
vmArg "-Dfabric-api.gametest"
vmArg "-Dfabric-api.gametest.report-file=${project.buildDir}/junit.xml"
runDir "build/gametest"
}
}

mods {
"macroengine-testmod" {
sourceSet sourceSets.main
sourceSet sourceSets.gametest
}
}
}

def TARGETS = [
"full" : 107,
"1_20_5" : 18 // 1.20.5-1.20.6, uses the 1_20_5/data overlay
"1_20_5" : 41 // 1.20.5-1.20.6, uses the 1_20_5/data overlay
]

def macroEngineSrc = file("datapacks/macroEngine")
Expand Down Expand Up @@ -222,7 +175,7 @@ TARGETS.each { label, packFormat ->
into(stageDir)
}

// 1_20_5 overlay: SADECE "1_20_5" (legacy, pack_format 18) hedefine uygulanir.
// 1_20_5 overlay: SADECE "1_20_5" (legacy, pack_format 41) hedefine uygulanir.
// "full" hedefinde uygulanmaz — aksi halde en guncel pack_format'a eski
// surum override'lari karisir ve geriye uyumluluk yamasi ileri surumu bozar.
if (label == "1_20_5") {
Expand Down Expand Up @@ -394,10 +347,3 @@ tasks.register('createSourceZip', Zip) {
archiveFileName = 'source-with-history.zip'
destinationDirectory = layout.buildDirectory.dir('archive')
}

tasks.register("runMainTestClient", JavaExec) {
group = "verification"
description = "Runs Main.java Test Client standalone"
classpath = sourceSets.gametest.runtimeClasspath
mainClass = "io.runtoolkit.macroengine.Main"
}
115 changes: 0 additions & 115 deletions build_jmc.py

This file was deleted.

24 changes: 0 additions & 24 deletions dependencies.json

This file was deleted.

7 changes: 0 additions & 7 deletions jmc_config.json

This file was deleted.

67 changes: 0 additions & 67 deletions main.jmc

This file was deleted.

Loading