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
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
The diff you're trying to view is too large. We only load the first 3000 changed files.
82 changes: 82 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,82 @@
name: Mineralogy 1.18.2 CI

on:
push:
branches:
- master-1.18.2
- 'feature/**'
pull_request:
branches:
- master-1.18.2

permissions:
contents: read

concurrency:
group: mineralogy-1.18-${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
build:
name: Build, test, and audit
runs-on: ubuntu-latest
timeout-minutes: 60

steps:
- name: Check out source
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7

- name: Install pinned Java 17 runtime and toolchain
uses: actions/setup-java@b6effb05e454b25005698d916606bdc6ffcbf961 # v5
with:
distribution: temurin
java-version: '17.0.1+12'

- name: Set up Gradle
uses: gradle/actions/setup-gradle@9c971963bec38e04b3d30dcc455b5382be2fdbfb # v6

- name: Stage exact OreSpawn release dependency
id: orespawn
run: |
mirror="$RUNNER_TEMP/orespawn-mirror"
bash gradle/stage-orespawn-release.sh "$mirror"
echo "repository=$mirror" >> "$GITHUB_OUTPUT"

- name: Build, test, and audit release artifacts
run: |
chmod +x ./gradlew
./gradlew clean check build javadoc verifyReleaseDependencies verifyReleaseArtifacts writeReleaseChecksums \
-PorespawnVerificationRepository="${{ steps.orespawn.outputs.repository }}" \
--no-daemon --stacktrace

- name: Generate and audit Eclipse production launches
run: >-
./gradlew genEclipseRuns eclipse isolateEclipseProductionRuns verifyEclipseProductionClasspath
-PorespawnVerificationRepository=${{ steps.orespawn.outputs.repository }}
--no-daemon --stacktrace

- name: Upload audited release candidate
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7
with:
name: Mineralogy-1.18.2-${{ github.sha }}
if-no-files-found: error
retention-days: 30
path: |
build/libs/Mineralogy-6.1.0.118021.jar
build/libs/Mineralogy-6.1.0.118021-sources.jar
build/libs/Mineralogy-6.1.0.118021-javadoc.jar
build/release/SHA256SUMS
CHANGELOG.txt

- name: Upload diagnostics on failure
if: failure()
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7
with:
name: Mineralogy-1.18.2-diagnostics-${{ github.sha }}
if-no-files-found: ignore
retention-days: 14
path: |
build/test-results/**
build/reports/**
build/*-run/logs/**
build/problems/**
47 changes: 47 additions & 0 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
name: CodeQL

on:
push:
branches:
- master-1.18.2
- 'feature/**'
pull_request:
branches:
- master-1.18.2

permissions:
actions: read
contents: read
security-events: write

jobs:
analyze:
name: Analyze Java
runs-on: ubuntu-latest
timeout-minutes: 45

steps:
- name: Check out source
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7

- name: Install pinned Java 17 runtime and toolchain
uses: actions/setup-java@b6effb05e454b25005698d916606bdc6ffcbf961 # v5
with:
distribution: temurin
java-version: '17.0.1+12'

- name: Set up Gradle
uses: gradle/actions/setup-gradle@9c971963bec38e04b3d30dcc455b5382be2fdbfb # v6

- name: Initialize CodeQL
uses: github/codeql-action/init@db488ddef3bf6cb639b32c2e9a7c0a7ea8271d28 # v4
with:
languages: java-kotlin

- name: Compile production code
run: |
chmod +x ./gradlew
./gradlew clean classes --rerun-tasks --no-build-cache --no-daemon --stacktrace

- name: Analyze
uses: github/codeql-action/analyze@db488ddef3bf6cb639b32c2e9a7c0a7ea8271d28 # v4
92 changes: 92 additions & 0 deletions .github/workflows/release-on-tag.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,92 @@
name: Validate Mineralogy release tag

on:
push:
tags:
- '*.*.*.*'

permissions:
actions: read
contents: read

concurrency:
group: mineralogy-release-tag-${{ github.ref_name }}
cancel-in-progress: false

jobs:
validate-release-tag:
name: Validate tag for manual release confirmation
if: github.repository == 'MinecraftModDevelopmentMods/MinecraftMineralogy'
runs-on: ubuntu-latest
timeout-minutes: 10

steps:
- name: Check out tagged source
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
with:
fetch-depth: 0

- name: Validate release tag, target metadata, and prior CI
env:
GH_TOKEN: ${{ github.token }}
run: |
set -euo pipefail

value() { sed -n "s/^$1=//p" gradle.properties; }
release_version="$(value mod_version)"
minecraft_version="$(value minecraft_version)"
loader_name="$(value loader_name)"
loader_code="$(value loader_code)"

IFS=. read -r mc_major mc_minor mc_patch extra <<<"$minecraft_version"
if [[ -n "${extra:-}" || -z "${mc_major:-}" || -z "${mc_minor:-}" ]]; then
echo "Invalid minecraft_version=$minecraft_version" >&2
exit 1
fi
mc_patch="${mc_patch:-0}"
if [[ ! "$mc_major" =~ ^[0-9]+$ || ! "$mc_minor" =~ ^[0-9]+$ || ! "$mc_patch" =~ ^[0-9]+$ ]]; then
echo "Invalid minecraft_version=$minecraft_version" >&2
exit 1
fi
case "$loader_name:$loader_code" in
forge:1|neoforge:2) ;;
*) echo "Invalid loader metadata $loader_name/$loader_code" >&2; exit 1 ;;
esac
printf -v minor_padded '%02d' "$((10#$mc_minor))"
printf -v patch_padded '%02d' "$((10#$mc_patch))"
target_suffix="${mc_major}${minor_padded}${patch_padded}${loader_code}"

if [[ ! "$release_version" =~ ^[0-9]+\.[0-9]+\.[0-9]+\.${target_suffix}$ ]]; then
echo "mod_version $release_version does not match $minecraft_version $loader_name target $target_suffix" >&2
exit 1
fi
if [[ "$GITHUB_REF_NAME" != "$release_version" ]]; then
echo "Release tag must equal mod_version $release_version; found $GITHUB_REF_NAME" >&2
exit 1
fi

successful_ci="$(gh api \
"repos/$GITHUB_REPOSITORY/commits/$GITHUB_SHA/check-runs?per_page=100" \
--jq '[.check_runs[] | select(.name == "Build, test, and audit" and .conclusion == "success")] | length')"
if [[ "$successful_ci" -lt 1 ]]; then
echo "The tagged commit has no successful Build, test, and audit check" >&2
exit 1
fi

- name: Record the manual publication interface
env:
RELEASE_WORKFLOW_URL: https://github.com/${{ github.repository }}/actions/workflows/deploy-release.yml
run: |
{
echo "## Release tag validated"
echo
echo "Tag \`$GITHUB_REF_NAME\` matches the selected target and has a successful Build, test, and audit check."
echo
echo "If this tag was created outside the release workflow, nothing has been published."
echo
echo "To start or recover publication, open [Release Mineralogy]($RELEASE_WORKFLOW_URL), select **Run workflow**, and enter:"
echo
echo "- release version: \`$GITHUB_REF_NAME\`"
echo "- CurseForge release level: \`release\`, \`beta\`, or \`alpha\`"
echo "- confirm live publication: checked"
} >> "$GITHUB_STEP_SUMMARY"
23 changes: 23 additions & 0 deletions .github/workflows/validate-gradle-build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: Validate Gradle Wrapper

on:
push:
branches:
- master-1.18.2
- 'feature/**'
pull_request:
branches:
- master-1.18.2

permissions:
contents: read

jobs:
validation:
name: Validation
runs-on: ubuntu-latest
steps:
- name: Check out source
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
- name: Validate wrapper integrity
uses: gradle/actions/wrapper-validation@9c971963bec38e04b3d30dcc455b5382be2fdbfb # v6
97 changes: 96 additions & 1 deletion CHANGELOG.txt
Original file line number Diff line number Diff line change
@@ -1 +1,96 @@
Mineralogy 1.12.x
Mineralogy 6.1.0.118021 for Minecraft 1.18.2

- Delegated terrain, strata, ore, and covered fluid-deposit generation to the
released OreSpawn 4.0.10.118021 provider engine, retaining the supported
`[4.0.6,5.0.0)` range; removed Mineralogy's parallel
geology, geome, ore, noise, and stone-replacement generators.
- Preserved all world-facing registry, tile, NBT, recipe, asset, patch, and
pre-flattening conversion identities while moving production packages to
zone.moddev.mc.mineralogy. Existing 1.10/1.12 chunks are protected during
1.18.2's flattening conversion. Legacy rock-furnace IDs are established
before Mojang data fixing, then all pre-namespaced tile IDs are made safe
before Forge constructs tile entities, so inventories and progress survive
and an uppercase vanilla ID cannot abort the complete chunk load.
Legacy state tables now support the complete 12-bit mod block-ID range in
both development and packaged runtimes, and each selected save reinstalls
its own numeric mapping after the client enumerates multiple old worlds.
- Added compatibility-safe controls for drywall, rock-salt lamps, mineral
dusts, and fertilizer, plus the stable five-way grouped creative tabs.
Disabled content remains registered and usable in established worlds.
- Preserved vertically mounted legacy rock-salt lamps on torch-supporting
blocks such as fences during pre-flattening world conversion.
- Made the historical `COBBLESTONE_EQUIVILENT` option functional through
target-native per-family block and item tags, including vanilla aliases,
reapplied after data reloads by updating the exact immutable tag objects
retained by already-parsed Forge 40 recipe ingredients. Chert and pumice
remain unconditional cobblestone equivalents.
- Added isolated Mineralogy crude-oil source and flowing fluids, block, bucket,
rendering resources, and the covered Ocean deposit declaration.
- Uses Minecraft 1.18's native granite, diorite, andesite, basalt, and tuff for
new OreSpawn terrain while retaining Mineralogy's historical registrations
and conversion aliases. Native smooth basalt joins Mineralogy's smooth-basalt
family without replacing Minecraft's basalt-smelting route. Deepslate remains
a terrain and ore host rather than becoming a construction family.
- Preserved rock-furnace save recovery and novaculite's 3/15/1 properties;
corrected replacement drop semantics and exact full-block Silk Touch results
for double slabs.
- Ported the accepted recipe contract as 1,427 native JSON recipes and matching
advancements: safe 4-to-1 mineral packing, charcoal and Base Metals dust
gunpowder routes, exact slabs, slab recombination, construction-form brick
conversions, progressive sand polishing, matching-slab rock furnaces, and
blank-to-marked relief progression. Each rock-furnace recipe is revealed as
soon as its matching slab is acquired, before a vanilla furnace is crafted.
- Reconciled Minecraft's native andesite, basalt, diorite, and granite with
their retained Mineralogy world-compatibility blocks. Native blocks now
unlock and feed every non-conflicting matching Mineralogy recipe. The four
vanilla 2x2 polished-block recipes are replaced by block-plus-sand routes so
the 2x2 recipes remain available for Mineralogy bricks. The six shared
andesite, diorite and granite slab recipes plus all nine matching stonecutter
routes now produce Mineralogy's more capable slabs, while the vanilla slabs
remain registered and tag-compatible. Twelve exact shapeless compatibility
recipes convert each raw or polished Mineralogy slab to its matching vanilla
slab and back at a lossless 1:1 ratio for modpacks that require an exact
vanilla item. Recipe advancements use the same exact item or family tag as
the recipe they reveal.
- Extended Minecraft 1.18's native stone crafting and tool-material tags so
every enabled cobblestone equivalent, including all 27 legacy rock families
and target-native aliases, works in the complete vanilla contract. Sixteen
conditional JSON overrides cover furnaces, brewing stands, redstone and
conversion recipes, and all stone tools without changing their IDs,
patterns, outputs or other ingredients. Disabled mode restores the native
ingredients and keeps blackstone, chert and pumice valid. Matching-slab
rock-furnace upgrades and vanilla cobblestone construction recipes remain
distinct.
- Prevented Forge 40 from silently reducing optional carbon- or coal-dust
gunpowder recipes to nitrate plus sulfur when their compatibility tag is
empty; every loaded gunpowder recipe now requires all three components.
- Added 17 reviewed UTF-8 JSON locales with the same 938 ordered keys, including
Brazilian and European Portuguese, Canadian French, Japanese, Korean, and
Russian.
- Added first-start player, developer, content, provider, and version guides,
plus an exact provider example. Existing exported guides are never
overwritten. Forge 40 Eclipse launches keep their required merged
`bin/main` mod output; if Eclipse removes Gradle's staged guide copies, the
exporter reads the authoritative source-checkout guides without weakening
packaged-jar validation.
- Added independent, atomic migration of valid non-default legacy ore settings
into a Mineralogy OreSpawn provider override, including deterministic reports
and exclusive-to-inclusive maximum-height conversion.
- Mineralogy 6.0 JSON upgrades now retain the original global and per-world
geology files byte-for-byte while mapping their old block-named rock and ore
entries onto Mineralogy's stable provider rule IDs. This prevents duplicate
ore generation and preserves world-specific geology choices on first start;
established OreSpawn files remain authoritative and reloads are byte-stable.
- Preserved 1.18-native wall tall-side blockstates and models, wall/item tags,
loot tables, fluid APIs, rendering setup, and pack format 9 resources.
- Added reproducible Java 17 main, sources, and Javadoc artifacts, exact released
OreSpawn dependency verification, guarded 1.18.2 CI, and the four-component
release tag `6.1.0.118021`.
- Kept ForgeGradle 7 while sealing Forge 40's required Mavenizer compatibility
fixture by SHA-256. The build-only tool runs on Java 25; Mineralogy compiles
and ships exclusively as Java 17, and release audits reject fixture leakage.
- Isolated CI's verified OreSpawn artifact in an exclusive Gradle repository so
dependency resolution cannot fall through to an unverified public copy.
Release verification also enforces Maven coordinate
`zone.moddev.mc.mineralogy:Mineralogy`, its generated POM, and the jar's
`Maven-Artifact` manifest entry.
Loading
Loading