This repository has been archived by the owner on Aug 23, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
71 lines (58 loc) · 1.65 KB
/
build.gradle
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
plugins {
id 'org.springframework.boot' version '3.0.0-M3'
id 'io.spring.dependency-management' version '1.0.11.RELEASE'
id "com.github.node-gradle.node" version "3.3.0"
id "io.github.guqing.plugin-development" version "0.0.5-SNAPSHOT"
id 'java'
}
group 'run.halo.wordpress'
version '0.0.2-SNAPSHOT'
sourceCompatibility = JavaVersion.VERSION_17
repositories {
maven { url 'https://repo.spring.io/milestone' }
mavenCentral()
}
bootJar {
enabled = false
}
jar {
enabled = true
duplicatesStrategy = DuplicatesStrategy.EXCLUDE
manifest.attributes(
'Plugin-Version': "${project.version}",
)
from {
configurations.runtimeClasspath.collect {
it.isDirectory() ? it : zipTree(it)
}
}
}
dependencies {
compileOnly "io.swagger.core.v3:swagger-core-jakarta:2.2.0"
compileOnly 'org.springframework.boot:spring-boot-starter-webflux'
compileOnly 'org.pf4j:pf4j:3.6.0'
compileOnly files("lib/halo-2.0.0-SNAPSHOT-plain.jar")
compileOnly 'org.projectlombok:lombok'
annotationProcessor 'org.projectlombok:lombok'
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.8.1'
testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine:5.8.1'
}
test {
useJUnitPlatform()
}
node {
nodeProjectDir = file("${project.projectDir}/console")
}
task buildFrontend(type: NpxTask) {
command = 'pnpm'
args = ['build']
}
task pnpmInstall(type: NpxTask) {
command = "pnpm"
args = ["install"]
}
build {
// build frontend before build
tasks.getByName('compileJava').dependsOn('buildFrontend')
tasks.getByName("buildFrontend").dependsOn("pnpmInstall")
}