Jump to content
View in the app

A better way to browse. Learn more.

Forge Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Plugin [id: 'net.minecraftforge.gradle', version: '5.1.+'] was not found in any of the following sources:

Featured Replies

Posted

I am trying to make a mc mod for the first time, but im getting this error whenever i run " gradlew genIntelliJRuns "

Here is the full output of my console:

C:\Users\redacted\Documents\first-mod>gradlew genIntelliJRuns
To honour the JVM settings for this build a single-use Daemon process will be forked. See https://docs.gradle.org/7.5/userguide/gradle_daemon.html#sec:disabling_the_daemon.
Daemon will be stopped at the end of the build

FAILURE: Build failed with an exception.

* Where:
Build file 'C:\Users\Artyom\Documents\first-mod\build.gradle' line: 4

* What went wrong:
Plugin [id: 'net.minecraftforge.gradle', version: '5.1'] was not found in any of the following sources:

- Gradle Core Plugins (plugin is not in 'org.gradle' namespace)
- Plugin Repositories (could not resolve plugin artifact 'net.minecraftforge.gradle:net.minecraftforge.gradle.gradle.plugin:5.1')
  Searched in the following repositories:
    Gradle Central Plugin Repository

* Try:
> Run with --stacktrace option to get the stack trace.
> Run with --info or --debug option to get more log output.
> Run with --scan to get full insights.

* Get more help at https://help.gradle.org

BUILD FAILED in 7s

and here is my build.gradle file:

plugins {
    id 'eclipse'
    id 'maven-publish'
    id 'net.minecraftforge.gradle' version '5.1.+'
}

version = '1.0'
group = 'io.github.artyomkulimov.firstmod' 
archivesBaseName = 'firstmod'

java.toolchain.languageVersion = JavaLanguageVersion.of(17)

println "Java: ${System.getProperty 'java.version'}, JVM: ${System.getProperty 'java.vm.version'} (${System.getProperty 'java.vendor'}), Arch: ${System.getProperty 'os.arch'}"
minecraft {

    mappings channel: 'official', version: '1.19.2'
    runs {
        client {
            workingDirectory project.file('run')

            mods {
                firstmod {
                    source sourceSets.main
                }
            }
        }

        server {
            workingDirectory project.file('run')

            mods {
                firstmod {
                    source sourceSets.main
                }
            }
        }


        gameTestServer {
            workingDirectory project.file('run')

            mods {
                firstmod {
                    source sourceSets.main
                }
            }
        }

        data {
            workingDirectory project.file('run')

            args '--mod', archivesBaseName, '--all', '--output', file('src/generated/resources/'), '--existing', file('src/main/resources/')

            mods {
                firstmod {
                    source sourceSets.main
                }
            }
        }
    }
}

sourceSets.main.resources { srcDir 'src/generated/resources' }

repositories {

}

dependencies {
    minecraft 'net.minecraftforge:forge:1.19.2-43.1.1'
}

jar {
    manifest {
        attributes([
                "Specification-Title"     : "First Mod",
                "Specification-Vendor"    : "wumpie",
                "Specification-Version"   : "1", 
                "Implementation-Title"    : project.name,
                "Implementation-Version"  : project.jar.archiveVersion,
                "Implementation-Vendor"   : "wumpie",
                "Implementation-Timestamp": new Date().format("yyyy-MM-dd'T'HH:mm:ssZ")
        ])
    }
}

jar.finalizedBy('reobfJar')

publishing {
    publications {
        mavenJava(MavenPublication) {
            artifact jar
        }
    }
    repositories {
        maven {
            url "file://${project.projectDir}/mcmodsrepo"
        }
    }
}

tasks.withType(JavaCompile).configureEach {
    options.encoding = 'UTF-8' 
}

 

Looks like you don't have forge's maven in your plugin repositories?

example from the mdk: https://github.com/MinecraftForge/MinecraftForge/blob/1.19.x/mdk/settings.gradle

Boilerplate:

If you don't post your logs/debug.log we can't help you. For curseforge you need to enable the forge debug.log in its minecraft settings. You should also post your crash report if you have one.

If there is no error in the log file and you don't have a crash report then post the launcher_log.txt from the minecraft folder. Again for curseforge this will be in your curseforge/minecraft/Install

Large files should be posted to a file sharing site like https://gist.github.com  You should also read the support forum sticky post.

  • 1 year later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.