|
1 | 1 | plugins { |
2 | 2 | id 'org.gradle.toolchains.foojay-resolver-convention' version '1.0.0' |
3 | | - |
4 | | - // NOTE: We need to load this into the classpath before GradleUtils for the service to load correctly |
5 | | - id 'io.freefair.javadoc-links' version '8.14' apply false // https://plugins.gradle.org/plugin/io.freefair.javadoc-links |
6 | | - |
7 | | - id 'net.minecraftforge.gradleutils' version '3.3.3' // https://plugins.gradle.org/plugin/net.minecraftforge.gradleutils |
8 | 3 | } |
9 | 4 |
|
10 | 5 | rootProject.name = 'forgedev' |
11 | 6 |
|
12 | | -dependencyResolutionManagement { |
13 | | - repositories { |
14 | | - mavenCentral() |
15 | | - maven gradleutils.forgeMaven |
16 | | - maven { url = 'https://maven.moddinglegacy.com/maven' } // Gradle API |
17 | | - //mavenLocal() |
| 7 | +// Applying plugins causes them to not have any IDE support when also applied to any build.gradle files |
| 8 | +// The workaround for now is to use this listener here so that it can stay in settings.gradle |
| 9 | +// See: https://youtrack.jetbrains.com/issue/IDEA-332061/Gradle-Missing-Code-Completion-Suggestions-for-Settings-Plugins-in-Groovy-DSL |
| 10 | +gradle.beforeProject { Project project -> |
| 11 | + project.pluginManager.withPlugin('net.minecraftforge.gradleutils') { |
| 12 | + project.repositories { |
| 13 | + mavenCentral() |
| 14 | + gradlePluginPortal() |
| 15 | + maven project.gradleutils.forgeMaven |
| 16 | + //mavenLocal() |
| 17 | + } |
18 | 18 | } |
| 19 | +} |
19 | 20 |
|
20 | | - //@formatter:off |
21 | | - versionCatalogs.register('libs') { |
22 | | - plugin 'licenser', 'net.minecraftforge.licenser' version '1.2.0' // https://plugins.gradle.org/plugin/net.minecraftforge.licenser |
23 | | - plugin 'gitversion', 'net.minecraftforge.gitversion' version '3.1.0' // https://plugins.gradle.org/plugin/net.minecraftforge.changelog |
24 | | - plugin 'changelog', 'net.minecraftforge.changelog' version '3.1.1' // https://plugins.gradle.org/plugin/net.minecraftforge.changelog |
25 | | - plugin 'plugin-publish', 'com.gradle.plugin-publish' version '2.0.0' // https://plugins.gradle.org/plugin/com.gradle.plugin-publish |
26 | | - plugin 'shadow', 'com.gradleup.shadow' version '9.1.0' // https://plugins.gradle.org/plugin/com.gradleup.shadow |
27 | | - |
28 | | - // Static Analysis |
29 | | - library 'nulls', 'org.jetbrains', 'annotations' version '26.0.2' |
30 | | - |
31 | | - // Gradle API |
32 | | - // TODO [ForgeGradle][FG7][Gradle Api] REMOVE once Gradle publish their own API artifacts |
33 | | - // Original: https://github.com/remal-gradle-api/packages/packages/760197 |
34 | | - // Mirror: https://maven.moddinglegacy.com/#browse/browse:maven-public:name%2Fremal%2Fgradle-api%2Fgradle-api%2F8.14.1 |
35 | | - version 'gradle', '9.0.0' |
36 | | - library 'gradle', 'name.remal.gradle-api', 'gradle-api' versionRef 'gradle' |
37 | | - |
38 | | - // GradleUtils Shared Base |
39 | | - library 'gradleutils-shared', 'net.minecraftforge', 'gradleutils-shared' version '3.3.3' |
40 | | - |
41 | | - library 'srgutils', 'net.minecraftforge', 'srgutils' version '0.5.14' |
42 | | - library 'fastcsv', 'de.siegmar', 'fastcsv' version '3.7.0' |
43 | | - |
44 | | - library 'utils-data', 'net.minecraftforge', 'json-data-utils' version '0.2.1' // https://files.minecraftforge.net/net/minecraftforge/json-data-utils/index.html |
45 | | - library 'utils-hash', 'net.minecraftforge', 'hash-utils' version '0.1.9' // https://files.minecraftforge.net/net/minecraftforge/hash-utils/index.html |
46 | | - library 'utils-download', 'net.minecraftforge', 'download-utils' version '0.3.1' // https://files.minecraftforge.net/net/minecraftforge/download-utils/index.html |
47 | | - library 'utils-files', 'net.minecraftforge', 'file-utils' version '0.3.1' // https://files.minecraftforge.net/net/minecraftforge/download-utils/index.html |
48 | | - bundle 'utils', ['utils-data', 'utils-hash', 'utils-download', 'utils-files'] |
49 | | - } |
50 | | - //@formatter:on |
| 21 | +//@formatter:off |
| 22 | +dependencyResolutionManagement.versionCatalogs.register('libs') { |
| 23 | + version 'gradleutils', '3.3.21' |
| 24 | + |
| 25 | + plugin 'licenser', 'net.minecraftforge.licenser' version '1.2.0' |
| 26 | + plugin 'gradleutils', 'net.minecraftforge.gradleutils' versionRef 'gradleutils' |
| 27 | + plugin 'gitversion', 'net.minecraftforge.gitversion' version '3.1.6' |
| 28 | + plugin 'changelog', 'net.minecraftforge.changelog' version '3.1.3' |
| 29 | + plugin 'plugin-publish', 'com.gradle.plugin-publish' version '2.0.0' |
| 30 | + plugin 'shadow', 'com.gradleup.shadow' version '9.2.2' |
| 31 | + |
| 32 | + // Static Analysis |
| 33 | + library 'nulls', 'org.jetbrains', 'annotations' version '26.0.2-1' |
| 34 | + |
| 35 | + // Gradle API |
| 36 | + version 'gradle', '9.2.0' |
| 37 | + library 'gradle', 'name.remal.gradle-api', 'gradle-api' versionRef 'gradle' |
| 38 | + |
| 39 | + // GradleUtils Shared Base |
| 40 | + library 'gradleutils-shared', 'net.minecraftforge', 'gradleutils-shared' versionRef 'gradleutils' |
| 41 | + |
| 42 | + library 'srgutils', 'net.minecraftforge', 'srgutils' version '0.5.14' |
| 43 | + library 'fastcsv', 'de.siegmar', 'fastcsv' version '3.7.0' |
| 44 | + |
| 45 | + library 'utils-data', 'net.minecraftforge', 'json-data-utils' version '0.2.1' // https://files.minecraftforge.net/net/minecraftforge/json-data-utils/index.html |
| 46 | + library 'utils-hash', 'net.minecraftforge', 'hash-utils' version '0.1.9' // https://files.minecraftforge.net/net/minecraftforge/hash-utils/index.html |
| 47 | + library 'utils-download', 'net.minecraftforge', 'download-utils' version '0.3.1' // https://files.minecraftforge.net/net/minecraftforge/download-utils/index.html |
| 48 | + library 'utils-files', 'net.minecraftforge', 'file-utils' version '0.3.1' // https://files.minecraftforge.net/net/minecraftforge/download-utils/index.html |
| 49 | + bundle 'utils', ['utils-data', 'utils-hash', 'utils-download', 'utils-files'] |
51 | 50 | } |
| 51 | +//@formatter:on |
0 commit comments