Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: adblockplussbrowser/build.gradle

Issue 29479601: Issue 5273 - Automatically update bundled lists (Closed)
Patch Set: Formatting and output when lists were updated Created July 7, 2017, 7:57 a.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | build.gradle » ('j') | build.gradle » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: adblockplussbrowser/build.gradle
===================================================================
--- a/adblockplussbrowser/build.gradle
+++ b/adblockplussbrowser/build.gradle
@@ -29,13 +29,29 @@ android {
release {
minifyEnabled true
proguardFiles getDefaultProguardFile('proguard-android.txt')
lintOptions {
disable 'MissingTranslation'
}
}
}
+
+ afterEvaluate { project ->
+ project.tasks.prepareReleaseDependencies << {
+ updateBundledLists()
+ println('Bundled lists updated at ' + new Date().format('dd MMM yyyy, HH:mm:ss zzz'))
+ }
+ }
+}
+
+def updateBundledLists() {
+ new URL(rootProject.ext.easyListUpdateUrl).withInputStream {
+ i -> new File(rootProject.ext.easyListFilePath).withOutputStream { it << i }
+ }
+ new URL(rootProject.ext.exceptionRulesUpdateUrl).withInputStream {
+ i -> new File(rootProject.ext.exceptionRulesFilePath).withOutputStream { it << i }
+ }
}
dependencies {
compile "com.android.support:support-v4:$rootProject.ext.androidSupportLibraryVersion"
}
« no previous file with comments | « no previous file | build.gradle » ('j') | build.gradle » ('J')

Powered by Google App Engine
This is Rietveld