mirror of
https://github.com/BetterAndroid/FlexiLocale.git
synced 2025-09-06 03:05:15 +08:00
Compare commits
50 Commits
Author | SHA1 | Date | |
---|---|---|---|
dbc41ac61e
|
|||
33b00fc4e0
|
|||
3a600b1b3e
|
|||
7d45821628
|
|||
3b86e41688
|
|||
9fb17f195f
|
|||
56ff6a109a
|
|||
99d7134a76
|
|||
220c78c4e2
|
|||
ce4a6f3c75
|
|||
76f2a5535f
|
|||
294913a9b1
|
|||
cd1eab47d7
|
|||
8e4a4615ab
|
|||
3da032b3bb
|
|||
4978774e39
|
|||
72c6d4c585
|
|||
1f3ac5c392
|
|||
018f6c305b
|
|||
2afa45fd97
|
|||
d3eeb338f6
|
|||
cd110085bb
|
|||
85ad3236c6
|
|||
0a10d05e09
|
|||
e18d33f1a8
|
|||
a48d15df5d
|
|||
c5ef7af843
|
|||
b0c8b08b7d
|
|||
14ddd6978c
|
|||
fcdf0b9f89
|
|||
189a1e2424
|
|||
be33fb489e
|
|||
9ef63252d1
|
|||
c90ac4e152
|
|||
2173620443
|
|||
0eb24e7a44
|
|||
54af0cbf2d
|
|||
95a24118cd
|
|||
0594a400b2
|
|||
88cffc01f7
|
|||
289f81cdd7
|
|||
d2005301db
|
|||
0885318a6e
|
|||
5eda5077b9
|
|||
a8f07f0d6b
|
|||
f968560d8b
|
|||
5ba66efd18
|
|||
ddd036b117
|
|||
bba646ce62
|
|||
adb2e3d643
|
@@ -10,6 +10,24 @@ ktlint_standard_argument-list-wrapping = disabled
|
||||
ktlint_standard_parameter-list-wrapping = disabled
|
||||
ktlint_standard_trailing-comma-on-declaration-site = disabled
|
||||
ktlint_function_signature_body_expression_wrapping = multiline
|
||||
ktlint_standard_string-template-indent = disabled
|
||||
ktlint_standard_function-signature = disabled
|
||||
ktlint_standard_trailing-comma-on-call-site = disabled
|
||||
ktlint_standard_multiline-expression-wrapping = disabled
|
||||
ktlint_standard_no-empty-first-line-in-class-body = disabled
|
||||
ktlint_standard_if-else-wrapping = disabled
|
||||
ktlint_standard_if-else-bracing = disabled
|
||||
ktlint_standard_statement-wrapping = disabled
|
||||
ktlint_standard_blank-line-before-declaration = disabled
|
||||
ktlint_standard_no-empty-file = disabled
|
||||
ktlint_standard_property-naming = disabled
|
||||
ktlint_standard_function-naming = disabled
|
||||
ktlint_standard_chain-method-continuation = disabled
|
||||
ktlint_standard_class-signature = disabled
|
||||
ktlint_standard_condition-wrapping = disabled
|
||||
ktlint_standard_class-signature = disabled
|
||||
ktlint_standard_no-trailing-spaces = disabled
|
||||
ktlint_standard_multiline-loop = disabled
|
||||
ij_continuation_indent_size = 2
|
||||
indent_size = 4
|
||||
indent_style = space
|
||||
|
132
.gitignore
vendored
132
.gitignore
vendored
@@ -1,42 +1,110 @@
|
||||
.gradle
|
||||
build/
|
||||
!gradle/wrapper/gradle-wrapper.jar
|
||||
!**/src/main/**/build/
|
||||
!**/src/test/**/build/
|
||||
## Fully .gtignore for IntelliJ, Android Studio and Gradle based Java projects
|
||||
## References:
|
||||
## - https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
|
||||
## - https://github.com/android/platform-samples/blob/main/.gitignore
|
||||
|
||||
### IntelliJ IDEA ###
|
||||
.idea/modules.xml
|
||||
.idea/jarRepositories.xml
|
||||
# User-specific stuff
|
||||
.idea/**/workspace.xml
|
||||
.idea/**/tasks.xml
|
||||
.idea/**/usage.statistics.xml
|
||||
.idea/**/dictionaries
|
||||
.idea/**/shelf
|
||||
|
||||
# AWS User-specific
|
||||
.idea/**/aws.xml
|
||||
|
||||
# Generated files
|
||||
.idea/**/contentModel.xml
|
||||
|
||||
# Sensitive or high-churn files
|
||||
.idea/**/dataSources/
|
||||
.idea/**/dataSources.ids
|
||||
.idea/**/dataSources.local.xml
|
||||
.idea/**/sqlDataSources.xml
|
||||
.idea/**/dynamic.xml
|
||||
.idea/**/uiDesigner.xml
|
||||
.idea/**/dbnavigator.xml
|
||||
|
||||
# Gradle
|
||||
.idea/**/gradle.xml
|
||||
.idea/**/libraries
|
||||
|
||||
# Gradle and Maven with auto-import
|
||||
.idea/.name
|
||||
.idea/artifacts
|
||||
.idea/compiler.xml
|
||||
.idea/libraries/
|
||||
*.iws
|
||||
.idea/jarRepositories.xml
|
||||
.idea/modules.xml
|
||||
.idea/*.iml
|
||||
.idea/modules
|
||||
.idea/caches
|
||||
.idea/material_theme**
|
||||
.idea/other.xml
|
||||
*.iml
|
||||
*.ipr
|
||||
|
||||
# Kotlin
|
||||
.kotlin
|
||||
|
||||
# Misc
|
||||
.idea/misc.xml
|
||||
|
||||
# CMake
|
||||
cmake-build-*/
|
||||
|
||||
# Mongo Explorer plugin
|
||||
.idea/**/mongoSettings.xml
|
||||
|
||||
# File-based project format
|
||||
*.iws
|
||||
|
||||
# IntelliJ
|
||||
out/
|
||||
!**/src/main/**/out/
|
||||
!**/src/test/**/out/
|
||||
|
||||
### Eclipse ###
|
||||
.apt_generated
|
||||
.classpath
|
||||
.factorypath
|
||||
.project
|
||||
.settings
|
||||
.springBeans
|
||||
.sts4-cache
|
||||
bin/
|
||||
!**/src/main/**/bin/
|
||||
!**/src/test/**/bin/
|
||||
# mpeltonen/sbt-idea plugin
|
||||
.idea_modules/
|
||||
|
||||
### NetBeans ###
|
||||
/nbproject/private/
|
||||
/nbbuild/
|
||||
/dist/
|
||||
/nbdist/
|
||||
/.nb-gradle/
|
||||
# JIRA plugin
|
||||
atlassian-ide-plugin.xml
|
||||
|
||||
### VS Code ###
|
||||
.vscode/
|
||||
# Cursive Clojure plugin
|
||||
.idea/replstate.xml
|
||||
|
||||
### Mac OS ###
|
||||
# SonarLint plugin
|
||||
.idea/sonarlint/
|
||||
|
||||
# Crashlytics plugin (for Android Studio and IntelliJ)
|
||||
com_crashlytics_export_strings.xml
|
||||
crashlytics.properties
|
||||
crashlytics-build.properties
|
||||
fabric.properties
|
||||
|
||||
# Editor-based Rest Client
|
||||
.idea/httpRequests
|
||||
|
||||
# Android studio 3.1+ serialized cache file
|
||||
.idea/caches/build_file_checksums.ser
|
||||
|
||||
# Android studio 3.1+ additional
|
||||
.idea/deployment*.xml
|
||||
.idea/assetWizardSettings.xml
|
||||
.idea/androidTestResultsUserPreferences.xml
|
||||
|
||||
# Android projects
|
||||
**/local.properties
|
||||
/captures
|
||||
.externalNativeBuild
|
||||
.cxx
|
||||
|
||||
# Gradle projects
|
||||
.gradle
|
||||
build/
|
||||
|
||||
# Mkdocs temporary serving folder
|
||||
docs-gen
|
||||
site
|
||||
*.bak
|
||||
.idea/appInsightsSettings.xml
|
||||
|
||||
# Mac OS
|
||||
.DS_Store
|
10
.idea/.gitignore
generated
vendored
10
.idea/.gitignore
generated
vendored
@@ -1,10 +0,0 @@
|
||||
# Default ignored files
|
||||
/shelf/
|
||||
/workspace.xml
|
||||
/gradle.xml
|
||||
/misc.xml
|
||||
# Editor-based HTTP Client requests
|
||||
/httpRequests/
|
||||
# Datasource local storage ignored files
|
||||
/dataSources/
|
||||
/dataSources.local.xml
|
6
.idea/AndroidProjectSystem.xml
generated
Normal file
6
.idea/AndroidProjectSystem.xml
generated
Normal file
@@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="AndroidProjectSystem">
|
||||
<option name="providerId" value="com.android.tools.idea.GradleProjectSystem" />
|
||||
</component>
|
||||
</project>
|
1
.idea/inspectionProfiles/Project_Default.xml
generated
1
.idea/inspectionProfiles/Project_Default.xml
generated
@@ -1,6 +1,7 @@
|
||||
<component name="InspectionProjectProfileManager">
|
||||
<profile version="1.0">
|
||||
<option name="myName" value="Project Default" />
|
||||
<inspection_tool class="CheckImageSize" enabled="false" level="WARNING" enabled_by_default="false" />
|
||||
<inspection_tool class="DuplicatedCode" enabled="true" level="WEAK WARNING" enabled_by_default="true" editorAttributes="INFO_ATTRIBUTES" />
|
||||
<inspection_tool class="ReplaceUntilWithRangeUntil" enabled="true" level="WEAK WARNING" enabled_by_default="true" />
|
||||
<inspection_tool class="SpellCheckingInspection" enabled="false" level="TYPO" enabled_by_default="false">
|
||||
|
2
.idea/kotlinc.xml
generated
2
.idea/kotlinc.xml
generated
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="KotlinJpsPluginSettings">
|
||||
<option name="version" value="1.9.10" />
|
||||
<option name="version" value="2.2.10" />
|
||||
</component>
|
||||
</project>
|
7
.idea/ktlint-plugin.xml
generated
Normal file
7
.idea/ktlint-plugin.xml
generated
Normal file
@@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="KtLint plugin">
|
||||
<ktlintMode>MANUAL</ktlintMode>
|
||||
<formatOnSave>false</formatOnSave>
|
||||
</component>
|
||||
</project>
|
@@ -1,15 +1,21 @@
|
||||
# Flexi Locale
|
||||
|
||||
[](https://github.com/BetterAndroid/FlexiLocale/blob/master/LICENSE)
|
||||
[](https://github.com/BetterAndroid/FlexiLocale/releases)
|
||||
[](https://t.me/BetterAndroid)
|
||||
[](https://t.me/HighCapable_Dev)
|
||||
[](https://github.com/BetterAndroid/FlexiLocale/blob/master/LICENSE)
|
||||
[](https://github.com/BetterAndroid/FlexiLocale/releases)
|
||||
[](https://t.me/BetterAndroid)
|
||||
[](https://t.me/HighCapable_Dev)
|
||||
[](https://qm.qq.com/cgi-bin/qm/qr?k=Pnsc5RY6N2mBKFjOLPiYldbAbprAU3V7&jump_from=webapi&authKey=X5EsOVzLXt1dRunge8ryTxDRrh9/IiW1Pua75eDLh9RE3KXE+bwXIYF5cWri/9lf)
|
||||
|
||||
<img src="https://github.com/BetterAndroid/FlexiLocale/blob/master/img-src/icon.png?raw=true" width = "100" height = "100" alt="LOGO"/>
|
||||
<img src="img-src/icon.png" width = "100" height = "100" alt="LOGO"/>
|
||||
|
||||
一个自动为 Android 项目生成国际化字符串调用的 Gradle 插件。
|
||||
|
||||
[English](https://github.com/BetterAndroid/FlexiLocale/blob/master/README.md) | 简体中文
|
||||
[English](README.md) | 简体中文
|
||||
|
||||
| <img src="https://github.com/BetterAndroid/.github/blob/main/img-src/logo.png?raw=true" width = "30" height = "30" alt="LOGO"/> | [BetterAndroid](https://github.com/BetterAndroid) |
|
||||
|---------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------|
|
||||
|
||||
这个项目属于上述组织,**点击上方链接关注这个组织**,发现更多好项目。
|
||||
|
||||
## 这是什么
|
||||
|
||||
@@ -57,19 +63,22 @@ var appName = locale.getAppName();
|
||||
|
||||
## 开始使用
|
||||
|
||||
- [点击这里](https://github.com/BetterAndroid/FlexiLocale/blob/master/docs/guide.md) 查看使用文档
|
||||
- [点击这里](docs/guide-zh-CN.md) 查看使用文档
|
||||
|
||||
## 更新日志
|
||||
|
||||
- [点击这里](https://github.com/BetterAndroid/FlexiLocale/blob/master/docs/changelog.md) 查看历史更新日志
|
||||
- [点击这里](docs/changelog-zh-CN.md) 查看历史更新日志
|
||||
|
||||
## 项目推广
|
||||
|
||||
如果你正在寻找一个可以自动管理 Gradle 项目依赖的 Gradle 插件,你可以了解一下 [SweetDependency](https://github.com/HighCapable/SweetDependency) 项目。
|
||||
|
||||
如果你正在寻找一个可以自动生成属性键值的 Gradle 插件,你可以了解一下 [SweetProperty](https://github.com/HighCapable/SweetProperty) 项目。
|
||||
|
||||
本项目同样使用了 **SweetDependency** 和 **SweetProperty**。
|
||||
<!--suppress HtmlDeprecatedAttribute -->
|
||||
<div align="center">
|
||||
<h2>嘿,还请君留步!👋</h2>
|
||||
<h3>这里有 Android 开发工具、UI 设计、Gradle 插件、Xposed 模块和实用软件等相关项目。</h3>
|
||||
<h3>如果下方的项目能为你提供帮助,不妨为我点个 star 吧!</h3>
|
||||
<h3>所有项目免费、开源,遵循对应开源许可协议。</h3>
|
||||
<h1><a href="https://github.com/fankes/fankes/blob/main/project-promote/README-zh-CN.md">→ 查看更多关于我的项目,请点击这里 ←</a></h1>
|
||||
</div>
|
||||
|
||||
## Star History
|
||||
|
||||
@@ -82,7 +91,7 @@ var appName = locale.getAppName();
|
||||
```
|
||||
Apache License Version 2.0
|
||||
|
||||
Copyright (C) 2019-2023 HighCapable
|
||||
Copyright (C) 2019 HighCapable
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
@@ -97,4 +106,4 @@ See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
```
|
||||
|
||||
版权所有 © 2019-2023 HighCapable
|
||||
版权所有 © 2019 HighCapable
|
41
README.md
41
README.md
@@ -1,15 +1,21 @@
|
||||
# Flexi Locale
|
||||
|
||||
[](https://github.com/BetterAndroid/FlexiLocale/blob/master/LICENSE)
|
||||
[](https://github.com/BetterAndroid/FlexiLocale/releases)
|
||||
[](https://t.me/BetterAndroid)
|
||||
[](https://t.me/HighCapable_Dev)
|
||||
[](https://github.com/BetterAndroid/FlexiLocale/blob/master/LICENSE)
|
||||
[](https://github.com/BetterAndroid/FlexiLocale/releases)
|
||||
[](https://t.me/BetterAndroid)
|
||||
[](https://t.me/HighCapable_Dev)
|
||||
[](https://qm.qq.com/cgi-bin/qm/qr?k=Pnsc5RY6N2mBKFjOLPiYldbAbprAU3V7&jump_from=webapi&authKey=X5EsOVzLXt1dRunge8ryTxDRrh9/IiW1Pua75eDLh9RE3KXE+bwXIYF5cWri/9lf)
|
||||
|
||||
<img src="https://github.com/BetterAndroid/FlexiLocale/blob/master/img-src/icon.png?raw=true" width = "100" height = "100" alt="LOGO"/>
|
||||
<img src="img-src/icon.png" width = "100" height = "100" alt="LOGO"/>
|
||||
|
||||
An easy generation Android i18ns string call Gradle plugin.
|
||||
|
||||
English | [简体中文](https://github.com/BetterAndroid/FlexiLocale/blob/master/README-zh-CN.md)
|
||||
English | [简体中文](README-zh-CN.md)
|
||||
|
||||
| <img src="https://github.com/BetterAndroid/.github/blob/main/img-src/logo.png?raw=true" width = "30" height = "30" alt="LOGO"/> | [BetterAndroid](https://github.com/BetterAndroid) |
|
||||
|---------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------|
|
||||
|
||||
This project belongs to the above-mentioned organization, **click the link above to follow this organization** and discover more good projects.
|
||||
|
||||
## What's this
|
||||
|
||||
@@ -60,21 +66,22 @@ Some functions may be incompatible, support will be gradually dropped in the fut
|
||||
|
||||
## Get Started
|
||||
|
||||
- [Click here](https://github.com/BetterAndroid/FlexiLocale/blob/master/docs/guide.md) to view the documentation
|
||||
- [Click here](docs/guide.md) to view the documentation
|
||||
|
||||
## Changelog
|
||||
|
||||
- [Click here](https://github.com/BetterAndroid/FlexiLocale/blob/master/docs/changelog.md) to view the historical changelog
|
||||
- [Click here](docs/changelog.md) to view the historical changelog
|
||||
|
||||
## Promotion
|
||||
|
||||
If you are looking for a Gradle plugin that can automatically manage Gradle project dependencies,
|
||||
you can check out the [SweetDependency](https://github.com/HighCapable/SweetDependency) project.
|
||||
|
||||
If you are looking for a Gradle plugin that can automatically generate properties key-values,
|
||||
you can check out the [SweetProperty](https://github.com/HighCapable/SweetProperty) project.
|
||||
|
||||
This project also uses **SweetDependency** and **SweetProperty**.
|
||||
<!--suppress HtmlDeprecatedAttribute -->
|
||||
<div align="center">
|
||||
<h2>Hey, please stay! 👋</h2>
|
||||
<h3>Here are related projects such as Android development tools, UI design, Gradle plugins, Xposed Modules and practical software. </h3>
|
||||
<h3>If the project below can help you, please give me a star! </h3>
|
||||
<h3>All projects are free, open source, and follow the corresponding open source license agreement. </h3>
|
||||
<h1><a href="https://github.com/fankes/fankes/blob/main/project-promote/README.md">→ To see more about my projects, please click here ←</a></h1>
|
||||
</div>
|
||||
|
||||
## Star History
|
||||
|
||||
@@ -87,7 +94,7 @@ This project also uses **SweetDependency** and **SweetProperty**.
|
||||
```
|
||||
Apache License Version 2.0
|
||||
|
||||
Copyright (C) 2019-2023 HighCapable
|
||||
Copyright (C) 2019 HighCapable
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
@@ -102,4 +109,4 @@ See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
```
|
||||
|
||||
Copyright © 2019-2023 HighCapable
|
||||
Copyright © 2019 HighCapable
|
@@ -1,16 +1,4 @@
|
||||
plugins {
|
||||
autowire(libs.plugins.kotlin.jvm) apply false
|
||||
}
|
||||
|
||||
allprojects {
|
||||
tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile>().configureEach {
|
||||
kotlinOptions {
|
||||
jvmTarget = "17"
|
||||
freeCompilerArgs = listOf(
|
||||
"-Xno-param-assertions",
|
||||
"-Xno-call-assertions",
|
||||
"-Xno-receiver-assertions"
|
||||
)
|
||||
}
|
||||
}
|
||||
autowire(libs.plugins.maven.publish) apply false
|
||||
}
|
@@ -2,4 +2,14 @@
|
||||
|
||||
## 1.0.0 | 2023.10.13
|
||||
|
||||
- 首个版本提交至 Maven
|
||||
- 首个版本提交至 Maven
|
||||
|
||||
## 1.0.1 | 2023.10.13
|
||||
|
||||
- 修复在使用 Kotlin on Android 插件的项目上找不到源码路径的问题
|
||||
|
||||
## 1.0.2 | 2025.08.19
|
||||
|
||||
- 修复在新版 Android Gradle Plugin 及 Android Studio/IDEA 中部署源码路径时的错误
|
||||
`removeContentEntry: removed content entry url 'build/generated/flexi-locale' still exists after removing`
|
||||
- 新增 `sourceSetName` 方法,允许自定义要部署的源集名称
|
@@ -2,4 +2,14 @@
|
||||
|
||||
## 1.0.0 | 2023.10.13
|
||||
|
||||
- The first version is submitted to Maven
|
||||
- The first version is submitted to Maven
|
||||
|
||||
## 1.0.1 | 2023.10.13
|
||||
|
||||
- Fixed a problem where the source code path could not be found on projects using the Kotlin on Android plugin
|
||||
|
||||
## 1.0.2 | 2025.08.19
|
||||
|
||||
- Fix errors when deploying source code paths in the new version of Android Gradle Plugin and Android Studio/IDEA
|
||||
`removeContentEntry: removed content entry url 'build/generated/flexi-locale' still exists after removing`
|
||||
- Added the `sourceSetName` method to allow customization of the source set name to be deployed
|
@@ -74,6 +74,10 @@ android {
|
||||
// 默认为 "build/generated/flexi-locale"
|
||||
// 建议将生成的代码放置于 "build" 目录下,因为生成的代码不建议去修改它
|
||||
generateDirPath = "build/generated/flexi-locale"
|
||||
// 自定义部署的 `sourceSet` 名称
|
||||
// 如果你的项目源码部署名称不是默认值,可以在这里自定义
|
||||
// 默认为 "main"
|
||||
sourceSetName = "main"
|
||||
// 自定义生成的包名
|
||||
// Android 项目默认使用 "android" 配置方法块中的 "namespace"
|
||||
// 你可以不进行设置,包名在一般情况下会自动进行匹配
|
||||
|
@@ -80,6 +80,10 @@ android {
|
||||
// Default is "build/generated/flexi-locale"
|
||||
// It is recommended to place the generated code in the "build" directory, because the generated code is not recommended to be modified
|
||||
generateDirPath = "build/generated/flexi-locale"
|
||||
// Custom deployed `sourceSet` name
|
||||
// If your project source code deployment name is not the default value, you can customize it here
|
||||
// Defaults to "main"
|
||||
sourceSetName = "main"
|
||||
// Customize the generated package name
|
||||
// Android projects use the "namespace" in the "android" configuration method block by default
|
||||
// You don't need to set it, the package name will be automatically matched under normal circumstances
|
||||
@@ -106,7 +110,9 @@ If you want to use it in Groovy DSL, please change the `=` of all variables to s
|
||||
Assume this is the `strings.xml` of your current project, divided into two directories: `default` and `zh-rCN`.
|
||||
|
||||
> values/strings.xml
|
||||
|
||||
```xml
|
||||
|
||||
<resources>
|
||||
<string name="app_name">My App</string>
|
||||
<string name="say_hello">Hello %1$s</string>
|
||||
@@ -116,6 +122,7 @@ Assume this is the `strings.xml` of your current project, divided into two direc
|
||||
> values-zh-rCN/strings.xml
|
||||
|
||||
```xml
|
||||
|
||||
<resources>
|
||||
<string name="app_name">我的应用</string>
|
||||
<string name="say_hello">你好 %1$s</string>
|
||||
|
2
flexilocal-gradle-plugin/.gitignore
vendored
2
flexilocal-gradle-plugin/.gitignore
vendored
@@ -1,2 +0,0 @@
|
||||
.gradle
|
||||
/build
|
@@ -1,65 +0,0 @@
|
||||
plugins {
|
||||
`kotlin-dsl`
|
||||
autowire(libs.plugins.kotlin.jvm)
|
||||
autowire(libs.plugins.maven.publish)
|
||||
}
|
||||
|
||||
allprojects {
|
||||
group = property.project.groupName
|
||||
version = property.project.version
|
||||
}
|
||||
|
||||
java {
|
||||
sourceCompatibility = JavaVersion.VERSION_17
|
||||
targetCompatibility = JavaVersion.VERSION_17
|
||||
withSourcesJar()
|
||||
}
|
||||
|
||||
kotlin {
|
||||
jvmToolchain(17)
|
||||
sourceSets.all { languageSettings { languageVersion = "2.0" } }
|
||||
}
|
||||
|
||||
dependencies {
|
||||
compileOnly(com.android.library.com.android.library.gradle.plugin)
|
||||
implementation(com.squareup.kotlinpoet)
|
||||
}
|
||||
|
||||
gradlePlugin {
|
||||
plugins {
|
||||
create(property.project.moduleName) {
|
||||
id = property.project.groupName
|
||||
implementationClass = property.gradle.plugin.implementationClass
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
mavenPublishing {
|
||||
coordinates(property.project.groupName, property.project.moduleName, property.project.version)
|
||||
pom {
|
||||
name = property.project.name
|
||||
description = property.project.description
|
||||
url = property.project.url
|
||||
licenses {
|
||||
license {
|
||||
name = property.project.licence.name
|
||||
url = property.project.licence.url
|
||||
distribution = property.project.licence.url
|
||||
}
|
||||
}
|
||||
developers {
|
||||
developer {
|
||||
id = property.project.developer.id
|
||||
name = property.project.developer.name
|
||||
email = property.project.developer.email
|
||||
}
|
||||
}
|
||||
scm {
|
||||
url = property.maven.publish.scm.url
|
||||
connection = property.maven.publish.scm.connection
|
||||
developerConnection = property.maven.publish.scm.developerConnection
|
||||
}
|
||||
}
|
||||
publishToMavenCentral(com.vanniktech.maven.publish.SonatypeHost.S01)
|
||||
signAllPublications()
|
||||
}
|
41
flexilocale-gradle-plugin/build.gradle.kts
Normal file
41
flexilocale-gradle-plugin/build.gradle.kts
Normal file
@@ -0,0 +1,41 @@
|
||||
plugins {
|
||||
`kotlin-dsl`
|
||||
autowire(libs.plugins.kotlin.jvm)
|
||||
autowire(libs.plugins.maven.publish)
|
||||
}
|
||||
|
||||
group = property.project.groupName
|
||||
version = property.project.version
|
||||
|
||||
java {
|
||||
sourceCompatibility = JavaVersion.VERSION_21
|
||||
targetCompatibility = JavaVersion.VERSION_21
|
||||
withSourcesJar()
|
||||
}
|
||||
|
||||
kotlin {
|
||||
jvmToolchain(21)
|
||||
sourceSets.all { languageSettings { languageVersion = "2.0" } }
|
||||
compilerOptions {
|
||||
freeCompilerArgs = listOf(
|
||||
"-Xno-param-assertions",
|
||||
"-Xno-call-assertions",
|
||||
"-Xno-receiver-assertions"
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
dependencies {
|
||||
compileOnly(com.android.library.com.android.library.gradle.plugin)
|
||||
compileOnly(org.jetbrains.kotlin.kotlin.gradle.plugin)
|
||||
implementation(com.squareup.kotlinpoet)
|
||||
}
|
||||
|
||||
gradlePlugin {
|
||||
plugins {
|
||||
create(property.project.moduleName) {
|
||||
id = property.project.groupName
|
||||
implementationClass = property.gradle.plugin.implementationClass
|
||||
}
|
||||
}
|
||||
}
|
@@ -1,6 +1,6 @@
|
||||
/*
|
||||
* FlexiLocale - An easy generation Android i18ns string call Gradle plugin.
|
||||
* Copyright (C) 2019-2023 HighCapable
|
||||
* Copyright (C) 2019 HighCapable
|
||||
* https://github.com/BetterAndroid/FlexiLocale
|
||||
*
|
||||
* Apache License Version 2.0
|
@@ -1,6 +1,6 @@
|
||||
/*
|
||||
* FlexiLocale - An easy generation Android i18ns string call Gradle plugin.
|
||||
* Copyright (C) 2019-2023 HighCapable
|
||||
* Copyright (C) 2019 HighCapable
|
||||
* https://github.com/BetterAndroid/FlexiLocale
|
||||
*
|
||||
* Apache License Version 2.0
|
||||
@@ -37,7 +37,7 @@ import org.gradle.api.plugins.ExtensionAware
|
||||
*/
|
||||
internal fun ExtensionAware.getOrCreate(name: String, clazz: Class<*>, vararg args: Any?) = name.toSafeExtName().let { sName ->
|
||||
runCatching { extensions.create(sName, clazz, *args).asExtension() }.getOrElse {
|
||||
if ((it is IllegalArgumentException && it.message?.startsWith("Cannot add extension with name") == true).not()) throw it
|
||||
if (!(it is IllegalArgumentException && it.message?.startsWith("Cannot add extension with name") == true)) throw it
|
||||
runCatching { extensions.getByName(sName).asExtension() }.getOrNull() ?: FError.make("Create or get extension failed with name \"$sName\"")
|
||||
}
|
||||
}
|
||||
@@ -50,7 +50,7 @@ internal fun ExtensionAware.getOrCreate(name: String, clazz: Class<*>, vararg ar
|
||||
*/
|
||||
internal inline fun <reified T> ExtensionAware.getOrCreate(name: String, vararg args: Any?) = name.toSafeExtName().let { sName ->
|
||||
runCatching { extensions.create(sName, T::class.java, *args) as T }.getOrElse {
|
||||
if ((it is IllegalArgumentException && it.message?.startsWith("Cannot add extension with name") == true).not()) throw it
|
||||
if (!(it is IllegalArgumentException && it.message?.startsWith("Cannot add extension with name") == true)) throw it
|
||||
runCatching { extensions.getByName(sName) as? T? }.getOrNull() ?: FError.make("Create or get extension failed with name \"$sName\"")
|
||||
}
|
||||
}
|
@@ -1,6 +1,6 @@
|
||||
/*
|
||||
* FlexiLocale - An easy generation Android i18ns string call Gradle plugin.
|
||||
* Copyright (C) 2019-2023 HighCapable
|
||||
* Copyright (C) 2019 HighCapable
|
||||
* https://github.com/BetterAndroid/FlexiLocale
|
||||
*
|
||||
* Apache License Version 2.0
|
@@ -1,6 +1,6 @@
|
||||
/*
|
||||
* FlexiLocale - An easy generation Android i18ns string call Gradle plugin.
|
||||
* Copyright (C) 2019-2023 HighCapable
|
||||
* Copyright (C) 2019 HighCapable
|
||||
* https://github.com/BetterAndroid/FlexiLocale
|
||||
*
|
||||
* Apache License Version 2.0
|
@@ -1,6 +1,6 @@
|
||||
/*
|
||||
* FlexiLocale - An easy generation Android i18ns string call Gradle plugin.
|
||||
* Copyright (C) 2019-2023 HighCapable
|
||||
* Copyright (C) 2019 HighCapable
|
||||
* https://github.com/BetterAndroid/FlexiLocale
|
||||
*
|
||||
* Apache License Version 2.0
|
@@ -1,6 +1,6 @@
|
||||
/*
|
||||
* FlexiLocale - An easy generation Android i18ns string call Gradle plugin.
|
||||
* Copyright (C) 2019-2023 HighCapable
|
||||
* Copyright (C) 2019 HighCapable
|
||||
* https://github.com/BetterAndroid/FlexiLocale
|
||||
*
|
||||
* Apache License Version 2.0
|
@@ -1,6 +1,6 @@
|
||||
/*
|
||||
* FlexiLocale - An easy generation Android i18ns string call Gradle plugin.
|
||||
* Copyright (C) 2019-2023 HighCapable
|
||||
* Copyright (C) 2019 HighCapable
|
||||
* https://github.com/BetterAndroid/FlexiLocale
|
||||
*
|
||||
* Apache License Version 2.0
|
||||
@@ -37,6 +37,11 @@ internal interface IFlexiLocaleConfigs {
|
||||
* "build/generated/[FlexiLocaleProperties.PROJECT_MODULE_NAME]"
|
||||
*/
|
||||
internal const val DEFAULT_GENERATE_DIR_PATH = "build/generated/${FlexiLocaleProperties.PROJECT_MODULE_NAME}"
|
||||
|
||||
/**
|
||||
* 默认的部署 `sourceSet` 名称
|
||||
*/
|
||||
internal const val DEFAULT_SOURCE_SET_NAME = "main"
|
||||
}
|
||||
|
||||
/** 是否启用插件 */
|
||||
@@ -45,6 +50,9 @@ internal interface IFlexiLocaleConfigs {
|
||||
/** 自定义生成的目录路径 */
|
||||
val generateDirPath: String
|
||||
|
||||
/** 自定义部署的 `sourceSet` 名称 */
|
||||
val sourceSetName: String
|
||||
|
||||
/** 自定义生成的包名 */
|
||||
val packageName: String
|
||||
|
||||
@@ -58,5 +66,5 @@ internal interface IFlexiLocaleConfigs {
|
||||
* 获取内部 [hashCode]
|
||||
* @return [Int]
|
||||
*/
|
||||
fun innerHashCode() = "$isEnable$generateDirPath$packageName$className$isEnableRestrictedAccess".hashCode()
|
||||
fun innerHashCode() = "$isEnable$generateDirPath$sourceSetName$packageName$className$isEnableRestrictedAccess".hashCode()
|
||||
}
|
@@ -1,6 +1,6 @@
|
||||
/*
|
||||
* FlexiLocale - An easy generation Android i18ns string call Gradle plugin.
|
||||
* Copyright (C) 2019-2023 HighCapable
|
||||
* Copyright (C) 2019 HighCapable
|
||||
* https://github.com/BetterAndroid/FlexiLocale
|
||||
*
|
||||
* Apache License Version 2.0
|
||||
@@ -59,6 +59,16 @@ open class FlexiLocaleConfigureExtension internal constructor() {
|
||||
var generateDirPath = IFlexiLocaleConfigs.DEFAULT_GENERATE_DIR_PATH
|
||||
@JvmName("generateDirPath") set
|
||||
|
||||
/**
|
||||
* 自定义部署的 `sourceSet` 名称
|
||||
*
|
||||
* 如果你的项目源码部署名称不是默认值 - 可以在这里自定义
|
||||
*
|
||||
* 默认为 [IFlexiLocaleConfigs.DEFAULT_SOURCE_SET_NAME]
|
||||
*/
|
||||
var sourceSetName = IFlexiLocaleConfigs.DEFAULT_SOURCE_SET_NAME
|
||||
@JvmName("sourceSetName") set
|
||||
|
||||
/**
|
||||
* 自定义生成的包名
|
||||
*
|
||||
@@ -91,25 +101,27 @@ open class FlexiLocaleConfigureExtension internal constructor() {
|
||||
internal fun build(project: Project): IFlexiLocaleConfigs {
|
||||
/** 检查合法包名 */
|
||||
fun String.checkingValidPackageName() {
|
||||
if (isNotBlank() && matches("^[a-zA-Z_][a-zA-Z0-9_]*(\\.[a-zA-Z_][a-zA-Z0-9_]*)*$".toRegex()).not())
|
||||
if (isNotBlank() && !matches("^[a-zA-Z_][a-zA-Z0-9_]*(\\.[a-zA-Z_][a-zA-Z0-9_]*)*$".toRegex()))
|
||||
FError.make("Invalid package name \"$this\"")
|
||||
}
|
||||
|
||||
/** 检查合法类名 */
|
||||
fun String.checkingValidClassName() {
|
||||
if (isNotBlank() && matches("^[a-zA-Z][a-zA-Z0-9_]*$".toRegex()).not())
|
||||
if (isNotBlank() && !matches("^[a-zA-Z][a-zA-Z0-9_]*$".toRegex()))
|
||||
FError.make("Invalid class name \"$this\"")
|
||||
}
|
||||
packageName.checkingValidPackageName()
|
||||
className.checkingValidClassName()
|
||||
val currentEnable = isEnable
|
||||
val currentGenerateDirPath = project.file(generateDirPath).absolutePath
|
||||
val currentSourceSetName = sourceSetName
|
||||
val currentPackageName = packageName
|
||||
val currentClassName = "${className.ifBlank { project.fullName().uppercamelcase() }}Locale"
|
||||
val currentEnableRestrictedAccess = isEnableRestrictedAccess
|
||||
return object : IFlexiLocaleConfigs {
|
||||
override val isEnable get() = currentEnable
|
||||
override val generateDirPath get() = currentGenerateDirPath
|
||||
override val sourceSetName get() = currentSourceSetName
|
||||
override val packageName get() = currentPackageName
|
||||
override val className get() = currentClassName
|
||||
override val isEnableRestrictedAccess get() = currentEnableRestrictedAccess
|
@@ -1,6 +1,6 @@
|
||||
/*
|
||||
* FlexiLocale - An easy generation Android i18ns string call Gradle plugin.
|
||||
* Copyright (C) 2019-2023 HighCapable
|
||||
* Copyright (C) 2019 HighCapable
|
||||
* https://github.com/BetterAndroid/FlexiLocale
|
||||
*
|
||||
* Apache License Version 2.0
|
@@ -1,6 +1,6 @@
|
||||
/*
|
||||
* FlexiLocale - An easy generation Android i18ns string call Gradle plugin.
|
||||
* Copyright (C) 2019-2023 HighCapable
|
||||
* Copyright (C) 2019 HighCapable
|
||||
* https://github.com/BetterAndroid/FlexiLocale
|
||||
*
|
||||
* Apache License Version 2.0
|
@@ -1,6 +1,6 @@
|
||||
/*
|
||||
* FlexiLocale - An easy generation Android i18ns string call Gradle plugin.
|
||||
* Copyright (C) 2019-2023 HighCapable
|
||||
* Copyright (C) 2019 HighCapable
|
||||
* https://github.com/BetterAndroid/FlexiLocale
|
||||
*
|
||||
* Apache License Version 2.0
|
||||
@@ -37,6 +37,8 @@ import com.highcapable.flexilocale.utils.debug.FError
|
||||
import com.highcapable.flexilocale.utils.debug.FLog
|
||||
import com.highcapable.flexilocale.utils.factory.toFile
|
||||
import org.gradle.api.Project
|
||||
import org.jetbrains.kotlin.gradle.dsl.KotlinAndroidProjectExtension
|
||||
import org.jetbrains.kotlin.gradle.dsl.KotlinProjectExtension
|
||||
import org.w3c.dom.Element
|
||||
import org.w3c.dom.Node
|
||||
import java.io.File
|
||||
@@ -53,6 +55,9 @@ internal object LocaleAnalysisHelper {
|
||||
/** Android 的 Library 插件名称 */
|
||||
private const val LIBRARY_PLUGIN_NAME = "com.android.library"
|
||||
|
||||
/** Kotlin 的 Android 插件名称 */
|
||||
private const val KT_ANDROID_PLUGIN_NAME = "org.jetbrains.kotlin.android"
|
||||
|
||||
/** I18ns 代码生成实例 */
|
||||
private val generator = LocaleSourcesGenerator()
|
||||
|
||||
@@ -81,7 +86,7 @@ internal object LocaleAnalysisHelper {
|
||||
*/
|
||||
internal fun start(project: Project, configs: IFlexiLocaleConfigs) {
|
||||
this.configs = configs
|
||||
if (configs.isEnable.not()) return
|
||||
if (!configs.isEnable) return
|
||||
checkingConfigsModified(project, configs)
|
||||
initializePlugins(project)
|
||||
val lastMappedStrings: LocaleStringMap = mutableMapOf()
|
||||
@@ -101,7 +106,7 @@ internal object LocaleAnalysisHelper {
|
||||
}
|
||||
}.clear()
|
||||
val isFileModified = mappedStrings != lastMappedStrings
|
||||
if (isFileModified.not() && isConfigsModified.not()) return
|
||||
if (!isFileModified && !isConfigsModified) return
|
||||
mappedStrings.clear()
|
||||
mappedStrings.putAll(lastMappedStrings)
|
||||
lastMappedStrings.clear()
|
||||
@@ -125,7 +130,12 @@ internal object LocaleAnalysisHelper {
|
||||
*/
|
||||
private fun initializePlugins(project: Project) {
|
||||
runCatching {
|
||||
fun BaseExtension.updateSourceDirs() = sourceSets.configureEach { kotlin.srcDir(configs.generateDirPath) }
|
||||
fun BaseExtension.updateSourceDirs() = sourceSets.firstOrNull {
|
||||
it.name == configs.sourceSetName
|
||||
}?.kotlin?.srcDir(configs.generateDirPath) ?: FLog.warn("Could not found source set \"${configs.sourceSetName}\"")
|
||||
fun KotlinProjectExtension.updateSourceDirs() = sourceSets.firstOrNull {
|
||||
it.name == configs.sourceSetName
|
||||
}?.kotlin?.srcDir(configs.generateDirPath) ?: FLog.warn("Could not found source set \"${configs.sourceSetName}\"")
|
||||
fun BaseVariant.updateResDirectories() = sourceSets.forEach { provide -> provide.resDirectories?.also { resDirectories.addAll(it) } }
|
||||
project.plugins.withId(APPLICATION_PLUGIN_NAME) {
|
||||
project.get<AppExtension>().also { extension ->
|
||||
@@ -143,6 +153,11 @@ internal object LocaleAnalysisHelper {
|
||||
}; extension.updateSourceDirs()
|
||||
}
|
||||
}
|
||||
project.plugins.withId(KT_ANDROID_PLUGIN_NAME) {
|
||||
project.get<KotlinAndroidProjectExtension>().also { extension ->
|
||||
extension.updateSourceDirs()
|
||||
}
|
||||
}
|
||||
}.onFailure { FError.make("Failed to initialize Android Gradle plugin, this may be not or a wrong Android project\n$it") }
|
||||
}
|
||||
|
||||
@@ -161,7 +176,7 @@ internal object LocaleAnalysisHelper {
|
||||
val valuesDirs: LocaleFileMap = mutableMapOf()
|
||||
forEach {
|
||||
it.listFiles()?.filter { dir -> dir.name.startsWith("values") }?.forEach eachDir@{ valuesDir ->
|
||||
if (valuesDir.exists().not() || valuesDir.isDirectory.not()) return@eachDir
|
||||
if (!valuesDir.exists() || !valuesDir.isDirectory) return@eachDir
|
||||
val langName = if (valuesDir.name == "values") "default" else valuesDir.name.split("s-").getOrNull(1) ?: return@eachDir
|
||||
if (valuesDirs[langName] == null) valuesDirs[langName] = mutableSetOf()
|
||||
valuesDirs[langName]?.add(valuesDir)
|
@@ -1,6 +1,6 @@
|
||||
/*
|
||||
* FlexiLocale - An easy generation Android i18ns string call Gradle plugin.
|
||||
* Copyright (C) 2019-2023 HighCapable
|
||||
* Copyright (C) 2019 HighCapable
|
||||
* https://github.com/BetterAndroid/FlexiLocale
|
||||
*
|
||||
* Apache License Version 2.0
|
@@ -1,6 +1,6 @@
|
||||
/*
|
||||
* FlexiLocale - An easy generation Android i18ns string call Gradle plugin.
|
||||
* Copyright (C) 2019-2023 HighCapable
|
||||
* Copyright (C) 2019 HighCapable
|
||||
* https://github.com/BetterAndroid/FlexiLocale
|
||||
*
|
||||
* Apache License Version 2.0
|
@@ -1,6 +1,6 @@
|
||||
/*
|
||||
* FlexiLocale - An easy generation Android i18ns string call Gradle plugin.
|
||||
* Copyright (C) 2019-2023 HighCapable
|
||||
* Copyright (C) 2019 HighCapable
|
||||
* https://github.com/BetterAndroid/FlexiLocale
|
||||
*
|
||||
* Apache License Version 2.0
|
@@ -1,6 +1,6 @@
|
||||
/*
|
||||
* FlexiLocale - An easy generation Android i18ns string call Gradle plugin.
|
||||
* Copyright (C) 2019-2023 HighCapable
|
||||
* Copyright (C) 2019 HighCapable
|
||||
* https://github.com/BetterAndroid/FlexiLocale
|
||||
*
|
||||
* Apache License Version 2.0
|
@@ -1,19 +1,27 @@
|
||||
# Project Configuration
|
||||
project.name=FlexiLocale
|
||||
project.description=An easy generation Android i18ns string call Gradle plugin.
|
||||
project.url=https://github.com/BetterAndroid/FlexiLocale
|
||||
project.groupName=com.highcapable.flexilocale
|
||||
project.moduleName=flexi-locale
|
||||
project.version=1.0.0
|
||||
project.licence.name=Apache License 2.0
|
||||
project.licence.url=https://github.com/BetterAndroid/FlexiLocale/blob/master/LICENSE
|
||||
project.developer.id="0"
|
||||
project.developer.name=fankes
|
||||
project.developer.email=qzmmcn@163.com
|
||||
project.version=1.0.2
|
||||
# Gradle Plugin Configuration
|
||||
gradle.plugin.moduleName=${project.groupName}.gradle.plugin
|
||||
gradle.plugin.implementationClass=${project.groupName}.plugin.FlexiLocalePlugin
|
||||
# Maven Publish Configuration
|
||||
maven.publish.scm.connection=scm:git:git://github.com/BetterAndroid/FlexiLocale.git
|
||||
maven.publish.scm.developerConnection=scm:git:ssh://github.com/BetterAndroid/FlexiLocale.git
|
||||
maven.publish.scm.url=https://github.com/BetterAndroid/FlexiLocale
|
||||
SONATYPE_HOST=CENTRAL_PORTAL
|
||||
RELEASE_SIGNING_ENABLED=true
|
||||
# Maven POM Configuration
|
||||
POM_NAME=FlexiLocale
|
||||
POM_ARTIFACT_ID=flexi-locale
|
||||
POM_DESCRIPTION=An easy generation Android i18ns string call Gradle plugin.
|
||||
POM_URL=https://github.com/BetterAndroid/FlexiLocale
|
||||
POM_LICENSE_NAME=Apache License 2.0
|
||||
POM_LICENSE_URL=https://github.com/BetterAndroid/FlexiLocale/blob/master/LICENSE
|
||||
POM_LICENSE_DIST=repo
|
||||
POM_SCM_URL=https://github.com/BetterAndroid/FlexiLocale
|
||||
POM_SCM_CONNECTION=scm:git:git://github.com/BetterAndroid/FlexiLocale.git
|
||||
POM_SCM_DEV_CONNECTION=scm:git:ssh://github.com/BetterAndroid/FlexiLocale.git
|
||||
POM_DEVELOPER_ID=0
|
||||
POM_DEVELOPER_NAME=fankes
|
||||
POM_DEVELOPER_EMAIL=qzmmcn@163.com
|
||||
POM_DEVELOPER_URL=https://github.com/fankes
|
@@ -11,15 +11,18 @@ repositories:
|
||||
plugins:
|
||||
org.jetbrains.kotlin.jvm:
|
||||
alias: kotlin-jvm
|
||||
version: 1.9.10
|
||||
version: 2.2.10
|
||||
com.vanniktech.maven.publish:
|
||||
alias: maven-publish
|
||||
version: 0.25.3
|
||||
version: 0.34.0
|
||||
|
||||
libraries:
|
||||
com.android.library:
|
||||
com.android.library.gradle.plugin:
|
||||
version: 8.1.2
|
||||
version: 8.12.1
|
||||
org.jetbrains.kotlin:
|
||||
kotlin-gradle-plugin:
|
||||
version: 2.2.10
|
||||
com.squareup:
|
||||
kotlinpoet:
|
||||
version: 1.14.2
|
||||
version: 2.2.0
|
2
gradle/wrapper/gradle-wrapper.properties
vendored
2
gradle/wrapper/gradle-wrapper.properties
vendored
@@ -1,5 +1,5 @@
|
||||
distributionBase=GRADLE_USER_HOME
|
||||
distributionPath=wrapper/dists
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.3-bin.zip
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.14.3-bin.zip
|
||||
zipStoreBase=GRADLE_USER_HOME
|
||||
zipStorePath=wrapper/dists
|
@@ -6,8 +6,8 @@ pluginManagement {
|
||||
}
|
||||
}
|
||||
plugins {
|
||||
id("com.highcapable.sweetdependency") version "1.0.2"
|
||||
id("com.highcapable.sweetproperty") version "1.0.3"
|
||||
id("com.highcapable.sweetdependency") version "1.0.4"
|
||||
id("com.highcapable.sweetproperty") version "1.0.8"
|
||||
}
|
||||
sweetDependency {
|
||||
isEnableVerboseMode = false
|
||||
@@ -16,10 +16,14 @@ sweetProperty {
|
||||
global {
|
||||
sourcesCode {
|
||||
className = rootProject.name
|
||||
includeKeys(
|
||||
"^project\\..*\$".toRegex(),
|
||||
"^gradle\\..*\$".toRegex()
|
||||
)
|
||||
isEnableRestrictedAccess = true
|
||||
}
|
||||
}
|
||||
rootProject { all { isEnable = false } }
|
||||
}
|
||||
rootProject.name = "FlexiLocale"
|
||||
include(":flexilocal-gradle-plugin")
|
||||
include(":flexilocale-gradle-plugin")
|
Reference in New Issue
Block a user