Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Resolve NeoForm & NeoForge ZIP-Archives Earlier to Access Configs in Specifications #86

Merged
merged 4 commits into from
Feb 3, 2024

Conversation

shartte
Copy link
Contributor

@shartte shartte commented Dec 23, 2023

The archives are already resolved during the Gradle configuration phase (out of necessity, since the config contained within is needed to build the task graph). Doing this in the Specification build allows us to load the config earlier and simplify the architecture a bit. I did check that subsequent runs just use the archives from the local Gradle artifact cache directly - same as the NG plugin jars and other Maven dependencies.

As a side-effect, this allows us to return Specification#getMinecraftVersion directly from the NeoForm configuration file, instead of attempting to parse it from the version string.

What needs extra attention is how the NeoForm version is handled when building userdev- and installer-profiles in NeoForgeDev. My intent is to build the NF runtime earlier, which resolves the effective version of NF. Then I use that resolved version in the profiles. This should result in a version range of + still leading to the local environment and the profiles using the exact same specific NF version.
To that end, I refactored how RuntimeDevRuntime is built by having it require a pre-built NeoFormRutime, instead of duplicating all configuration parameters of the NeoFormRuntime in the RuntimeDevRuntime.

Supersedes #93 too, since I fixed the grammar in here too.

@marchermans marchermans enabled auto-merge (squash) January 3, 2024 11:35
…re resolved earlier. That allows simplification of the runtime specifications by resolving the configuration files in the archives when the specifications are built.
@neoforged-pr-publishing
Copy link

neoforged-pr-publishing bot commented Feb 3, 2024

  • Publish PR to GitHub Packages

Last commit published: 243c3c81063081249ebfa260c653d62d6a49a3b6.

PR Publishing

The artifacts published by this PR:

Repository Declaration

In order to use the artifacts published by the PR, add the following repository to your buildscript:

repositories {
    maven {
        name 'Maven for PR #86' // https://github.com/neoforged/NeoGradle/pull/86
        url 'https://prmaven.neoforged.net/NeoGradle/pr86'
        content {
            includeModule('net.neoforged.gradle', 'dsl-common')
            includeModule('net.neoforged.gradle', 'dsl-neoform')
            includeModule('net.neoforged.gradle', 'userdev')
            includeModule('net.neoforged.gradle', 'dsl-vanilla')
            includeModule('net.neoforged.gradle', 'utils')
            includeModule('net.neoforged.gradle', 'dsl-userdev')
            includeModule('net.neoforged.gradle', 'dsl-platform')
            includeModule('net.neoforged.gradle', 'mixin')
            includeModule('net.neoforged.gradle.platform', 'net.neoforged.gradle.platform.gradle.plugin')
            includeModule('net.neoforged.gradle.vanilla', 'net.neoforged.gradle.vanilla.gradle.plugin')
            includeModule('net.neoforged.gradle', 'vanilla')
            includeModule('net.neoforged.gradle', 'dsl-mixin')
            includeModule('net.neoforged.gradle.common', 'net.neoforged.gradle.common.gradle.plugin')
            includeModule('net.neoforged.gradle', 'common')
            includeModule('net.neoforged.gradle', 'platform')
            includeModule('net.neoforged.gradle.mixin', 'net.neoforged.gradle.mixin.gradle.plugin')
            includeModule('net.neoforged.gradle', 'neoform')
            includeModule('net.neoforged.gradle.userdev', 'net.neoforged.gradle.userdev.gradle.plugin')
            includeModule('net.neoforged.gradle.neoform', 'net.neoforged.gradle.neoform.gradle.plugin')
        }
    }
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant