mirror of
https://github.com/darksaid98/Carbon.git
synced 2026-12-04 14:38:49 +00:00
Include git metadata in manifest, commit hash in snapshot platform versions
This commit is contained in:
2 files changed
+37
-1
No files matched your search
@@ -3,6 +3,8 @@ plugins {
|
||||
id("com.modrinth.minotaur")
|
||||
}
|
||||
|
||||
decorateVersion()
|
||||
|
||||
val runtimeDownload: Configuration by configurations.creating {
|
||||
isCanBeResolved = true
|
||||
isCanBeConsumed = false
|
||||
@@ -41,6 +43,15 @@ dependencies {
|
||||
}
|
||||
|
||||
tasks {
|
||||
jar {
|
||||
manifest {
|
||||
attributes(
|
||||
"carbon-version" to project.version,
|
||||
"carbon-commit" to lastCommitHash(),
|
||||
"carbon-branch" to currentBranch(),
|
||||
)
|
||||
}
|
||||
}
|
||||
val copyJar = register<FileCopyTask>("copyJar") {
|
||||
fileToCopy.set(platformExtension.jarTask.flatMap { it.archiveFile })
|
||||
destination.set(rootProject.layout.buildDirectory.dir("libs").flatMap {
|
||||
|
||||
Reference in new issue
Block a user