赞
踩
Could not create task ‘:generateLockfiles’.
rootProject.tasks.register('generateLockfiles') {
rootProject.subprojects.each { subproject ->
def gradlew = (OperatingSystem.current().isWindows()) ?
"${rootProject.projectDir}/gradlew.bat" : "${rootProject.projectDir}/gradlew"
rootProject.exec {
workingDir rootProject.projectDir
executable gradlew
args ":${subproject.name}:dependencies", "--write-locks"
if (isFlutterAppProject()) {
rootProject.tasks.register('generateLockfiles') {
rootProject.subprojects.each { subproject ->
def gradlew = (OperatingSystem.current().isWindows()) ?
"${rootProject.projectDir}/gradlew.bat" : "${rootProject.projectDir}/gradlew"
rootProject.exec {
workingDir rootProject.projectDir
executable gradlew
args ":${subproject.name}:dependencies", "--write-locks"
}
}
}
}
Configure project :flutter
卡在了flutter 子工程的依赖构建(混合开发时引入),然后busy 导致守护线程不停启动直至电脑卡死(Android Studio 4.1).
从阅读源码上来看,旧版本的flutter在组件化的安卓项目中没有对module做 ‘是否为flutter module’的判断,去执行了 ./gradlew 脚本导致线程等待卡死.
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。