mirror of
https://github.com/MaintainTeam/LastPipeBender.git
synced 2025-03-01 05:48:22 +03:00
BraveNewPipe: convert to doLast in testReplaceMailandJsonandSignature()
and really match two lines
This commit is contained in:
parent
38e9f03fb0
commit
04fc10bb67
1 changed files with 8 additions and 6 deletions
|
@ -100,7 +100,7 @@ ext.alterFilesAndVerify = { targetDir, isTest ->
|
||||||
|
|
||||||
replaceAndVerify('m', false, targetDir,
|
replaceAndVerify('m', false, targetDir,
|
||||||
/* filename: */ 'org/schabi/newpipe/NewVersionWorker.kt',
|
/* filename: */ 'org/schabi/newpipe/NewVersionWorker.kt',
|
||||||
/* match: */ '(private const val NEWPIPE_API_URL =).*',
|
/* match: */ '(private const val NEWPIPE_API_URL =).*\n.*',
|
||||||
/* replace: */ '\\1\n "https://raw.githubusercontent.com/bravenewpipe/bnp-r-mgr/master/api/data.json"',
|
/* replace: */ '\\1\n "https://raw.githubusercontent.com/bravenewpipe/bnp-r-mgr/master/api/data.json"',
|
||||||
/* verify: */ '"https://raw.githubusercontent.com/bravenewpipe/bnp-r-mgr/master/api/data.json"')
|
/* verify: */ '"https://raw.githubusercontent.com/bravenewpipe/bnp-r-mgr/master/api/data.json"')
|
||||||
}
|
}
|
||||||
|
@ -200,12 +200,14 @@ task bravify() {
|
||||||
// does this job for you automatically. To be re-run if needed.
|
// does this job for you automatically. To be re-run if needed.
|
||||||
// -- evermind --
|
// -- evermind --
|
||||||
task testReplaceMailandJsonandSignature() {
|
task testReplaceMailandJsonandSignature() {
|
||||||
return // enable only when you want it to run
|
group = "braveTest"
|
||||||
|
|
||||||
|
doLast {
|
||||||
// modify .{java,kt} files
|
// modify .{java,kt} files
|
||||||
def relativeDirFile = 'src/main/java'
|
def relativeDirFile = 'src/main/java'
|
||||||
def sourceDir = "${rootDir}/app/${relativeDirFile}/"
|
def sourceDir = "${rootDir}/app/${relativeDirFile}/"
|
||||||
alterFilesAndVerify(sourceDir, true)
|
alterFilesAndVerify(sourceDir, true)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//-----------------------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------------------
|
||||||
|
|
Loading…
Add table
Reference in a new issue