Package net.fabricmc.loom.task.prod
Class AbstractProductionRunTask
java.lang.Object
org.gradle.api.internal.AbstractTask
org.gradle.api.DefaultTask
net.fabricmc.loom.task.AbstractLoomTask
net.fabricmc.loom.task.prod.AbstractProductionRunTask
- All Implemented Interfaces:
Comparable<org.gradle.api.Task>,org.gradle.api.internal.DynamicObjectAware,org.gradle.api.internal.TaskInternal,org.gradle.api.Named,org.gradle.api.plugins.ExtensionAware,org.gradle.api.Task,org.gradle.util.Configurable<org.gradle.api.Task>
- Direct Known Subclasses:
ClientProductionRunTask,ServerProductionRunTask
@Experimental
@UntrackedTask(because="Always rerun this task.")
public abstract sealed class AbstractProductionRunTask
extends AbstractLoomTask
permits ClientProductionRunTask, ServerProductionRunTask
This is the base task for running the game in a "production" like environment. Using intermediary names, and not enabling development only features.
Do not use this task directly, use ClientProductionRunTask or ServerProductionRunTask instead.
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.gradle.api.Named
org.gradle.api.Named.Namer -
Field Summary
Fields inherited from interface org.gradle.api.Task
TASK_ACTION, TASK_CONSTRUCTOR_ARGS, TASK_DEPENDS_ON, TASK_DESCRIPTION, TASK_GROUP, TASK_NAME, TASK_OVERWRITE, TASK_TYPE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidconfigureClasspath(org.gradle.process.ExecSpec exec) protected voidconfigureCommand(org.gradle.process.ExecSpec exec) protected voidconfigureJvmArgs(org.gradle.process.ExecSpec exec) protected voidconfigureMainClass(org.gradle.process.ExecSpec exec) protected voidconfigureProgramArgs(org.gradle.process.ExecSpec exec) protected org.gradle.api.provider.Provider<org.gradle.api.artifacts.Configuration> detachedConfigurationProvider(String mavenNotation, org.gradle.api.provider.Provider<String> versionProvider) protected abstract org.gradle.api.file.ConfigurableFileCollectionprotected abstract org.gradle.process.ExecOperationsabstract org.gradle.api.provider.Property<org.gradle.jvm.toolchain.JavaLauncher> TheJavaLauncherto use when running the game, this can be used to specify a specific Java version to use.protected abstract org.gradle.jvm.toolchain.JavaToolchainServiceabstract org.gradle.api.provider.ListProperty<String> A list of additional JVM arguments to pass to the game.protected abstract org.gradle.api.provider.Property<String> abstract org.gradle.api.file.ConfigurableFileCollectiongetMods()A collection of mods that will be used when running the game.abstract org.gradle.api.provider.ListProperty<String> A list of additional program arguments to pass to the game.protected org.gradle.api.provider.Provider<String> abstract org.gradle.api.file.DirectoryPropertyThe directory to run the game in.voidrun()Methods inherited from class net.fabricmc.loom.task.AbstractLoomTask
getExtension, getModPlatformMethods inherited from class org.gradle.api.DefaultTask
compareTo, configure, dependsOn, doFirst, doFirst, doFirst, doLast, doLast, doLast, finalizedBy, getActions, getAnt, getDependsOn, getDescription, getDestroyables, getDidWork, getEnabled, getExtensions, getFinalizedBy, getGroup, getInputs, getLocalState, getLogger, getLogging, getMustRunAfter, getName, getOutputs, getPath, getProject, getShouldRunAfter, getState, getTaskDependencies, getTemporaryDir, getTimeout, hasProperty, mustRunAfter, onlyIf, onlyIf, onlyIf, property, setActions, setDependsOn, setDescription, setDidWork, setEnabled, setFinalizedBy, setGroup, setMustRunAfter, setOnlyIf, setOnlyIf, setOnlyIf, setProperty, setShouldRunAfter, shouldRunAfter, usesServiceMethods inherited from class org.gradle.api.internal.AbstractTask
acceptServiceReferences, appendParallelSafeAction, doNotTrackState, doNotTrackStateIf, getAsDynamicObject, getIdentityPath, getImpliesSubProjects, getLifecycleDependencies, getOnlyIf, getReasonNotToTrackState, getReasonsNotToTrackState, getReasonTaskIsIncompatibleWithConfigurationCache, getRequiredServices, getServices, getSharedResources, getStandardOutputCapture, getTaskActions, getTaskIdentity, getTemporaryDirFactory, hasTaskActions, injectIntoNewInstance, isCompatibleWithConfigurationCache, isEnabled, isHasCustomActions, notCompatibleWithConfigurationCache, prependParallelSafeAction, restoreOnlyIf, restoreTaskActions, setImpliesSubProjectsMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.gradle.api.Task
doNotTrackState, notCompatibleWithConfigurationCache
-
Constructor Details
-
AbstractProductionRunTask
@Inject public AbstractProductionRunTask()
-
-
Method Details
-
getMods
@Classpath public abstract org.gradle.api.file.ConfigurableFileCollection getMods()A collection of mods that will be used when running the game. The mods must be remapped to run with intermediary names.By default this includes the remapped jar.
-
getJvmArgs
A list of additional JVM arguments to pass to the game. -
getProgramArgs
A list of additional program arguments to pass to the game. -
getRunDir
@OutputDirectory public abstract org.gradle.api.file.DirectoryProperty getRunDir()The directory to run the game in. -
getJavaLauncher
public abstract org.gradle.api.provider.Property<org.gradle.jvm.toolchain.JavaLauncher> getJavaLauncher()TheJavaLauncherto use when running the game, this can be used to specify a specific Java version to use.See: Java Toolchains
- Returns:
-
getClasspath
@Internal @Classpath protected abstract org.gradle.api.file.ConfigurableFileCollection getClasspath() -
getMainClass
-
getExecOperations
@Inject protected abstract org.gradle.process.ExecOperations getExecOperations() -
getJavaToolchainService
@Inject protected abstract org.gradle.jvm.toolchain.JavaToolchainService getJavaToolchainService() -
run
- Throws:
IOException
-
configureCommand
protected void configureCommand(org.gradle.process.ExecSpec exec) -
configureJvmArgs
protected void configureJvmArgs(org.gradle.process.ExecSpec exec) -
streamClasspath
-
configureClasspath
protected void configureClasspath(org.gradle.process.ExecSpec exec) -
configureMainClass
protected void configureMainClass(org.gradle.process.ExecSpec exec) -
configureProgramArgs
protected void configureProgramArgs(org.gradle.process.ExecSpec exec) -
getProjectLoaderVersion
-
detachedConfigurationProvider
-