mirror of
https://github.com/halo-dev/plugin-starter.git
synced 2025-10-13 22:56:50 +00:00
50 lines
1.1 KiB
Groovy
50 lines
1.1 KiB
Groovy
plugins {
|
|
id 'java'
|
|
id "com.github.node-gradle.node" version "5.0.0"
|
|
id "io.freefair.lombok" version "8.0.1"
|
|
id "run.halo.plugin.devtools" version "0.0.7"
|
|
}
|
|
|
|
group 'run.halo.starter'
|
|
sourceCompatibility = JavaVersion.VERSION_17
|
|
|
|
repositories {
|
|
mavenCentral()
|
|
maven { url 'https://s01.oss.sonatype.org/content/repositories/releases' }
|
|
maven { url 'https://s01.oss.sonatype.org/content/repositories/snapshots/' }
|
|
maven { url 'https://repo.spring.io/milestone' }
|
|
}
|
|
|
|
dependencies {
|
|
implementation platform('run.halo.tools.platform:plugin:2.11.0-SNAPSHOT')
|
|
compileOnly 'run.halo.app:api'
|
|
|
|
testImplementation 'run.halo.app:api'
|
|
testImplementation 'org.springframework.boot:spring-boot-starter-test'
|
|
}
|
|
|
|
test {
|
|
useJUnitPlatform()
|
|
}
|
|
|
|
tasks.withType(JavaCompile).configureEach {
|
|
options.encoding = "UTF-8"
|
|
}
|
|
|
|
node {
|
|
nodeProjectDir = file("${project.projectDir}/ui")
|
|
}
|
|
|
|
task buildFrontend(type: PnpmTask) {
|
|
args = ['build']
|
|
}
|
|
|
|
build {
|
|
// build frontend before build
|
|
tasks.getByName('compileJava').dependsOn('buildFrontend')
|
|
}
|
|
|
|
halo {
|
|
version = '2.11'
|
|
}
|