mirror of
https://github.com/flutter/flutter.git
synced 2025-06-03 00:51:18 +00:00
Clean up output directory before copying over new files (#14085)
* Clean up output directory before copying over new files * Use standard clean task command
This commit is contained in:
parent
6e38b42919
commit
09a6df7461
@ -321,6 +321,7 @@ class FlutterPlugin implements Plugin<Project> {
|
|||||||
Task copyFlxTask = project.tasks.create(name: "copyFlutterAssets${variant.name.capitalize()}", type: Copy) {
|
Task copyFlxTask = project.tasks.create(name: "copyFlutterAssets${variant.name.capitalize()}", type: Copy) {
|
||||||
dependsOn flutterTask
|
dependsOn flutterTask
|
||||||
dependsOn variant.mergeAssets
|
dependsOn variant.mergeAssets
|
||||||
|
dependsOn "clean${variant.mergeAssets.name.capitalize()}"
|
||||||
into variant.mergeAssets.outputDir
|
into variant.mergeAssets.outputDir
|
||||||
with flutterTask.assets
|
with flutterTask.assets
|
||||||
}
|
}
|
||||||
@ -453,7 +454,9 @@ class FlutterTask extends BaseFlutterTask {
|
|||||||
CopySpec getAssets() {
|
CopySpec getAssets() {
|
||||||
return project.copySpec {
|
return project.copySpec {
|
||||||
from "${intermediateDir}"
|
from "${intermediateDir}"
|
||||||
|
|
||||||
include "flutter_assets/**" // the working dir and its files
|
include "flutter_assets/**" // the working dir and its files
|
||||||
|
|
||||||
if (buildMode != 'debug') {
|
if (buildMode != 'debug') {
|
||||||
if (preferSharedLibrary) {
|
if (preferSharedLibrary) {
|
||||||
include "${intermediateDir}/app.so"
|
include "${intermediateDir}/app.so"
|
||||||
|
Loading…
Reference in New Issue
Block a user