From f0d8f2c611361cb317e1c67dd2cc00b7360a666b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=99=BD=E5=87=A4=E5=90=89?= Date: Tue, 22 Jul 2025 10:51:41 +0800 Subject: [PATCH] =?UTF-8?q?fix:=E6=89=A7=E8=A1=8Cgradle=E7=9A=84bootJar?= =?UTF-8?q?=E6=97=B6=E6=8C=87=E5=AE=9Aprod?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- build.gradle | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/build.gradle b/build.gradle index 92ea793..1f18f82 100644 --- a/build.gradle +++ b/build.gradle @@ -49,6 +49,11 @@ dependencies { testRuntimeOnly 'org.junit.platform:junit-platform-launcher'// JUnit 平台运行时,用于在测试时启动 JUnit Platform(例如在 IDE 或构建工具中运行测试) } +bootJar { + launchScript { + properties 'spring.profiles.active': 'prod' + } +} tasks.named('test') { useJUnitPlatform()