A mod declares a dependency on a mod or library through Gradle, through the <code>dependencies</code> block.<ref>[https://docs.gradle.org/7.1.1/userguide/declaring_dependencies.html Gradle User Guide: ''Declaring dependencies'']</ref>
+
A mod declares a dependency on a mod or library through Gradle, through the <code>dependencies</code> block.<ref>[https://docs.gradle.org/7.4.2/userguide/declaring_dependencies.html Gradle User Guide: ''Declaring dependencies'']</ref>
For example, to declare a dependency on the <code>net:minecraftforge:eventbus:5.0.3</code> library from the <code>main</code> source set:
For example, to declare a dependency on the <code>net:minecraftforge:eventbus:5.0.3</code> library from the <code>main</code> source set:
Line 54:
Line 54:
</syntaxhighlight>
</syntaxhighlight>
−
When a dependency artifact is searched for in a flat directory repository, it will look for the following files in order (<code>''ext''</code> defaults to <code>jar</code>)<ref>[https://github.com/gradle/gradle/blob/v7.1.1/subprojects/core-api/src/main/java/org/gradle/api/artifacts/repositories/FlatDirectoryArtifactRepository.java gradle/gradle; tag v7.1.1; org.gradle.api.artifacts.repositories.FlatDirectoryArtifactRepository]</ref>:
+
When a dependency artifact is searched for in a flat directory repository, it will look for the following files in order (<code>''ext''</code> defaults to <code>jar</code>)<ref>[https://github.com/gradle/gradle/blob/v7.4.2/subprojects/core-api/src/main/java/org/gradle/api/artifacts/repositories/FlatDirectoryArtifactRepository.java gradle/gradle; tag v7.4.2; org.gradle.api.artifacts.repositories.FlatDirectoryArtifactRepository]</ref>: