diff options
| author | 2024-01-08 04:30:52 +0100 | |
|---|---|---|
| committer | 2024-01-08 04:30:52 +0100 | |
| commit | d65833c6ce3d2bf9c486198ca0bb6e59ac13c73a (patch) | |
| tree | 10665b7cf6193800589facade908b37d9ea42f31 | |
| parent | Created the EMC system (diff) | |
| download | mc-eris-alchemy-d65833c6ce3d2bf9c486198ca0bb6e59ac13c73a.tar.gz mc-eris-alchemy-d65833c6ce3d2bf9c486198ca0bb6e59ac13c73a.tar.xz mc-eris-alchemy-d65833c6ce3d2bf9c486198ca0bb6e59ac13c73a.zip | |
Made gradle publish work
| -rw-r--r-- | build.gradle.kts | 19 | ||||
| -rw-r--r-- | gradle.properties | 1 | ||||
| -rw-r--r-- | gradle/wrapper/gradle-wrapper.properties | 2 |
3 files changed, 19 insertions, 3 deletions
diff --git a/build.gradle.kts b/build.gradle.kts index 6b30db9..b4bd891 100644 --- a/build.gradle.kts +++ b/build.gradle.kts | |||
| @@ -7,6 +7,7 @@ val groupid: String by project | |||
| 7 | val jakartaAnnotationVersion: String by project | 7 | val jakartaAnnotationVersion: String by project |
| 8 | val loaderVersion: String by project | 8 | val loaderVersion: String by project |
| 9 | val modid: String by project | 9 | val modid: String by project |
| 10 | val modVersion: String by project | ||
| 10 | val minecraftVersion: String by project | 11 | val minecraftVersion: String by project |
| 11 | val patchouliVersion: String by project | 12 | val patchouliVersion: String by project |
| 12 | val quiltMappings: String by project | 13 | val quiltMappings: String by project |
| @@ -16,8 +17,8 @@ base { | |||
| 16 | archivesName = modid | 17 | archivesName = modid |
| 17 | } | 18 | } |
| 18 | 19 | ||
| 19 | version = "0.1+${minecraftVersion}" | ||
| 20 | group = groupid | 20 | group = groupid |
| 21 | version = "${modVersion}+${minecraftVersion}" | ||
| 21 | 22 | ||
| 22 | repositories { | 23 | repositories { |
| 23 | maven { | 24 | maven { |
| @@ -79,9 +80,14 @@ java { | |||
| 79 | sourceCompatibility = JavaVersion.VERSION_17 | 80 | sourceCompatibility = JavaVersion.VERSION_17 |
| 80 | targetCompatibility = JavaVersion.VERSION_17 | 81 | targetCompatibility = JavaVersion.VERSION_17 |
| 81 | 82 | ||
| 83 | withJavadocJar() | ||
| 82 | withSourcesJar() | 84 | withSourcesJar() |
| 83 | } | 85 | } |
| 84 | 86 | ||
| 87 | tasks.javadoc { | ||
| 88 | (options as StandardJavadocDocletOptions).addBooleanOption("html5", true) | ||
| 89 | } | ||
| 90 | |||
| 85 | tasks.jar { | 91 | tasks.jar { |
| 86 | from("LICENSE") { | 92 | from("LICENSE") { |
| 87 | rename { "${it}_${base.archivesName.get()}" } | 93 | rename { "${it}_${base.archivesName.get()}" } |
| @@ -91,9 +97,18 @@ tasks.jar { | |||
| 91 | publishing { | 97 | publishing { |
| 92 | publications { | 98 | publications { |
| 93 | create<MavenPublication>("maven") { | 99 | create<MavenPublication>("maven") { |
| 100 | artifactId = modid | ||
| 94 | from(components["java"]) | 101 | from(components["java"]) |
| 95 | } | 102 | } |
| 96 | } | 103 | } |
| 97 | 104 | ||
| 98 | repositories {} | 105 | repositories { |
| 106 | maven { | ||
| 107 | url = uri("https://mvn.enes.lv/") | ||
| 108 | credentials { | ||
| 109 | username = (findProperty("mvnUsername") ?: System.getenv("MVN_USERNAME")).toString() | ||
| 110 | password = (findProperty("mvnPassword") ?: System.getenv("MVN_PASSWORD")).toString() | ||
| 111 | } | ||
| 112 | } | ||
| 113 | } | ||
| 99 | } | 114 | } |
diff --git a/gradle.properties b/gradle.properties index aad323e..fd88dd2 100644 --- a/gradle.properties +++ b/gradle.properties | |||
| @@ -3,6 +3,7 @@ org.gradle.parallel = true | |||
| 3 | 3 | ||
| 4 | groupid = lv.enes.mc | 4 | groupid = lv.enes.mc |
| 5 | modid = eris_alchemy | 5 | modid = eris_alchemy |
| 6 | modVersion = 0.1-SNAPSHOT | ||
| 6 | 7 | ||
| 7 | loomPluginVersion = 1.4.1 | 8 | loomPluginVersion = 1.4.1 |
| 8 | 9 | ||
diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index e6aba25..1af9e09 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | distributionBase=GRADLE_USER_HOME | 1 | distributionBase=GRADLE_USER_HOME |
| 2 | distributionPath=wrapper/dists | 2 | distributionPath=wrapper/dists |
| 3 | distributionUrl=https\://services.gradle.org/distributions/gradle-8.5-all.zip | 3 | distributionUrl=https\://services.gradle.org/distributions/gradle-8.5-bin.zip |
| 4 | networkTimeout=10000 | 4 | networkTimeout=10000 |
| 5 | validateDistributionUrl=true | 5 | validateDistributionUrl=true |
| 6 | zipStoreBase=GRADLE_USER_HOME | 6 | zipStoreBase=GRADLE_USER_HOME |