mirror of https://github.com/halo-dev/halo
Refactor processResources with creating a new copy task (#7446)
#### What type of PR is this? /kind improvement /area core /milestone 2.21.x #### What this PR does / why we need it: Defining `into` property in `processResources` task is not working, so I create a new copy task to process UI dist. #### Does this PR introduce a user-facing change? ```release-note None ```pull/7449/head^2
parent
44cae84bc7
commit
7eadf7a889
|
@ -97,7 +97,7 @@ tasks.register('createChecksums', Checksum) {
|
||||||
checksumAlgorithm = Checksum.Algorithm.SHA256
|
checksumAlgorithm = Checksum.Algorithm.SHA256
|
||||||
}
|
}
|
||||||
|
|
||||||
tasks.named('processResources', ProcessResources) {
|
tasks.register('copyUiDist', Copy) {
|
||||||
from project(':ui').layout.buildDirectory.dir('dist')
|
from project(':ui').layout.buildDirectory.dir('dist')
|
||||||
into layout.buildDirectory.dir('resources/main')
|
into layout.buildDirectory.dir('resources/main')
|
||||||
configure {
|
configure {
|
||||||
|
@ -105,6 +105,10 @@ tasks.named('processResources', ProcessResources) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
tasks.named('processResources', ProcessResources) {
|
||||||
|
dependsOn tasks.named('copyUiDist')
|
||||||
|
}
|
||||||
|
|
||||||
tasks.named('build') {
|
tasks.named('build') {
|
||||||
dependsOn tasks.named('createChecksums')
|
dependsOn tasks.named('createChecksums')
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue