resolve the problem that config doesn't update when remove the config closure in build.gradle & sync it #223
+19
−19
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
解决自动生成的repluginHostConfig文件中的配置信息未更新问题
Description
测试IDE:android studio 2.3.2
1.在宿主的build.gradle中配置了repluginHostConfig闭包,并编译,生成的repluginHostConfig文件配置信息生效
2.在宿主的build.gradle中移除了repluginHostConfig闭包,并点击'同步gradle'按钮,repluginHostConfig文件配置信息未更新
原因:修改build.gradle后,同步gradle,但是宿主gradle插件中的RepluginConfig类的静态变量仍保存着上一次构建的值,而且因为build.gradle中删除了配置信息,并不会从build.gradle中更新这些静态变量。