Compare commits

...

3 Commits

Author SHA1 Message Date
Bogdan Terehov d4d0d1b75d create string file if this not exist 2025-10-23 17:17:20 +03:00
Anton Badretdinov 60b1e4a3e9 update BuildScripts plugins 2025-04-09 16:05:59 +03:00
Anton Badretdinov d6315b283d Add core:base_feature and core:strings modules 2025-04-08 12:10:55 +03:00
4 changed files with 9 additions and 4 deletions

View File

@ -52,7 +52,7 @@ abstract class ApiGeneratorPlugin : Plugin<Project> {
val outputLanguage = extension.outputLanguage ?: throw IllegalStateException("Configure output language code for api generator plugin")
javaexec {
main = "-jar"
mainClass.set("-jar")
workingDir = rootDir
args = listOfNotNull(
configurations.getByName("apiGenerator").asPath,

View File

@ -63,7 +63,7 @@ class SwaggerApiGeneratorAndroidPlugin : Plugin<Project> {
workingDir = file(taskWorkingDir)
classpath = files(configurations.getByName(GENERATOR_CONFIG).asPath,
configurations.getByName(TI_GENERATOR_CONFIG).asPath)
main = "io.swagger.codegen.v3.cli.SwaggerCodegen"
mainClass.set("io.swagger.codegen.v3.cli.SwaggerCodegen")
args = listOfNotNull(
"generate",
"-i",

View File

@ -42,7 +42,7 @@ class CpdLinter : Linter {
}
tasks.withType<Cpd> {
reports.xml.required.set(true)
reports.xml.destination = getCpdReportFile()
reports.xml.outputLocation.set(getCpdReportFile())
ignoreFailures = true
source = getSources(extension.excludes)
}

View File

@ -2,7 +2,7 @@ import groovy.json.JsonSlurper
import groovy.xml.MarkupBuilder
task stringGenerator {
generate(android.languageMap, project)
generate(android.languageMap, project.rootProject.findProject(":core:strings"))
println("Strings generated!")
}
@ -32,6 +32,11 @@ private def generate(Map<String, String> sources, Project project) {
}
def stringsFile = getFile(key, key == defaultLang, project)
if (!stringsFile.exists()) {
stringsFile.parentFile.mkdirs()
stringsFile.createNewFile()
}
stringsFile.write(sw.toString(), "UTF-8")
}
}