From 6946719ea769423a275faa74db9e33d04e71f6a8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=A6=82=E6=A2=A6=E6=8A=80=E6=9C=AF?= <596392912@qq.com> Date: Fri, 21 May 2021 16:27:05 +0800 Subject: [PATCH] =?UTF-8?q?:sparkles:=20=E4=BC=98=E5=8C=96=20jar=20manifes?= =?UTF-8?q?t?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 1 + gradle/publish-maven.gradle | 5 ++++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 75b76df..d77ef68 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,7 @@ ## [2.1.0] - 2021-05-21 ### 新功能 - :sparkles: 支持 gradle 增量编译 +- :sparkles: 优化 jar manifest - :arrow_up: 升级 Spring boot 到 2.5.0 - :arrow_up: 升级 lombok 到 1.18.20 - :arrow_up: 升级 google auto 到 1.0 diff --git a/gradle/publish-maven.gradle b/gradle/publish-maven.gradle index d288a29..d0dff98 100644 --- a/gradle/publish-maven.gradle +++ b/gradle/publish-maven.gradle @@ -4,7 +4,10 @@ apply plugin: 'maven-publish' jar { afterEvaluate { manifest { - attributes 'Implementation-Version': version + attributes["Implementation-Title"] = project.name + attributes["Implementation-Version"] = project.version + attributes["Automatic-Module-Name"] = project.name.replace('-', '.') // for Jigsaw + attributes["Created-By"] = "${System.getProperty("java.version")} (${System.getProperty("java.specification.vendor")})" } } } -- GitLab