Copy the other file in this gist into your $GRADLE_USER_HOME/init.d
(usually this is:
~/.gradle/init.d/installMinecraft.init.gradle.kts
) and replace the installation path with the correct path.
From now on, every mod project that uses forgegradle or loom (and a roughly standard project layout) should have
the task ./gradlew installToMinecraft
available (also available in your IDE), which will install that jar.
in projects with multiple subprojects, you might want to use a fully qualified task path: Either
./gradlew :installToMinecraft
for installing the root project, or ./gradlew :forge-1.8.9:installToMinecraft
to install a subproject (for example for multi-version projects).
This does not parse the modid (since the format of mod metadata varies a lot, so archiveBaseName
has to be set
correctly (or the old file won't be deleted)