fucking crowdin
This commit is contained in:
parent
2211b35513
commit
1dca64f916
1 changed files with 10 additions and 10 deletions
20
build.gradle
20
build.gradle
|
@ -253,7 +253,7 @@ tasks.sourcesJar.dependsOn runDatagen
|
||||||
jar {
|
jar {
|
||||||
exclude "**/*.psd"
|
exclude "**/*.psd"
|
||||||
from file('src/main/generated')
|
from file('src/main/generated')
|
||||||
from { crowdin.getDidWork() ? fileTree('build/translations').matching{exclude "**/en_US.json"} : null}
|
from { fileTree('build/translations').matching{exclude "**/en_US.json"} }
|
||||||
|
|
||||||
// A bit of a hack to allow the generated sources when they already exist
|
// A bit of a hack to allow the generated sources when they already exist
|
||||||
duplicatesStrategy = DuplicatesStrategy.EXCLUDE
|
duplicatesStrategy = DuplicatesStrategy.EXCLUDE
|
||||||
|
@ -279,15 +279,15 @@ tasks.register('crowdinExport') {
|
||||||
def translationsUrl = "https://crowdin.com/backend/download/project/techreborn.zip"
|
def translationsUrl = "https://crowdin.com/backend/download/project/techreborn.zip"
|
||||||
def translationsZip = file("build/translations.zip")
|
def translationsZip = file("build/translations.zip")
|
||||||
|
|
||||||
tasks.register('crowdin') {
|
// tasks.register('crowdin') {
|
||||||
dependsOn crowdinExport
|
// dependsOn crowdinExport
|
||||||
description "Downloads translations from CrowdIn"
|
// description "Downloads translations from CrowdIn"
|
||||||
outputs.file translationsZip
|
// outputs.file translationsZip
|
||||||
|
|
||||||
doLast {
|
// doLast {
|
||||||
translationsZip.bytes = new URL(translationsUrl).bytes
|
// translationsZip.bytes = new URL(translationsUrl).bytes
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
|
|
||||||
tasks.register('cleanCrowdin', Delete) {
|
tasks.register('cleanCrowdin', Delete) {
|
||||||
description "Delete old translations"
|
description "Delete old translations"
|
||||||
|
@ -296,7 +296,7 @@ tasks.register('cleanCrowdin', Delete) {
|
||||||
clean.dependsOn cleanCrowdin
|
clean.dependsOn cleanCrowdin
|
||||||
|
|
||||||
tasks.register('renameCrowdin', Copy) {
|
tasks.register('renameCrowdin', Copy) {
|
||||||
dependsOn crowdin
|
// dependsOn crowdin
|
||||||
description "Renames the translation files to be all lower case"
|
description "Renames the translation files to be all lower case"
|
||||||
from zipTree(translationsZip)
|
from zipTree(translationsZip)
|
||||||
into file('build/translations')
|
into file('build/translations')
|
||||||
|
|
Loading…
Reference in a new issue