diff --git a/.templates/README.md b/.templates/README.md new file mode 100644 index 0000000..8af2473 --- /dev/null +++ b/.templates/README.md @@ -0,0 +1,4 @@ +# Templates + +This folder contains templates to generate your modules in Intellij Idea with plugin +[ModuleGenerator](https://plugins.jetbrains.com/plugin/21100-segment-generator) diff --git a/.templates/mpp_android_module/ModuleGenerator.json b/.templates/mpp_android_module/ModuleGenerator.json new file mode 100644 index 0000000..98a38a3 --- /dev/null +++ b/.templates/mpp_android_module/ModuleGenerator.json @@ -0,0 +1,5 @@ +{ + "module_path": "feature/sample", + "module_package": "{{.module_path.replace(\"/\", \".\")}}", + "full_module_package": "project_group.{{.module_path.replace(\"/\", \".\")}}" +} diff --git a/.templates/mpp_android_module/{{.module_path.lowercase()}}/build.gradle b/.templates/mpp_android_module/{{.module_path.lowercase()}}/build.gradle new file mode 100644 index 0000000..2170ae4 --- /dev/null +++ b/.templates/mpp_android_module/{{.module_path.lowercase()}}/build.gradle @@ -0,0 +1,8 @@ +plugins { + id "org.jetbrains.kotlin.multiplatform" + id "org.jetbrains.kotlin.plugin.serialization" + id "com.android.library" +} + +apply from: "$mppAndroidProjectPresetPath" + diff --git a/.templates/mpp_android_module/{{.module_path.lowercase()}}/src/commonMain/kotlin/PackageInfo.kt b/.templates/mpp_android_module/{{.module_path.lowercase()}}/src/commonMain/kotlin/PackageInfo.kt new file mode 100644 index 0000000..04b059d --- /dev/null +++ b/.templates/mpp_android_module/{{.module_path.lowercase()}}/src/commonMain/kotlin/PackageInfo.kt @@ -0,0 +1 @@ +package {{.full_module_package}} diff --git a/.templates/mpp_android_module/{{.module_path.lowercase()}}/src/main/AndroidManifest.xml b/.templates/mpp_android_module/{{.module_path.lowercase()}}/src/main/AndroidManifest.xml new file mode 100644 index 0000000..ae51a89 --- /dev/null +++ b/.templates/mpp_android_module/{{.module_path.lowercase()}}/src/main/AndroidManifest.xml @@ -0,0 +1 @@ + diff --git a/.templates/mpp_java_module/ModuleGenerator.json b/.templates/mpp_java_module/ModuleGenerator.json new file mode 100644 index 0000000..98a38a3 --- /dev/null +++ b/.templates/mpp_java_module/ModuleGenerator.json @@ -0,0 +1,5 @@ +{ + "module_path": "feature/sample", + "module_package": "{{.module_path.replace(\"/\", \".\")}}", + "full_module_package": "project_group.{{.module_path.replace(\"/\", \".\")}}" +} diff --git a/.templates/mpp_java_module/{{.module_path.lowercase()}}/build.gradle b/.templates/mpp_java_module/{{.module_path.lowercase()}}/build.gradle new file mode 100644 index 0000000..61d425e --- /dev/null +++ b/.templates/mpp_java_module/{{.module_path.lowercase()}}/build.gradle @@ -0,0 +1,7 @@ +plugins { + id "org.jetbrains.kotlin.multiplatform" + id "org.jetbrains.kotlin.plugin.serialization" +} + +apply from: "$mppJavaProjectPresetPath" + diff --git a/.templates/mpp_java_module/{{.module_path.lowercase()}}/src/commonMain/kotlin/PackageInfo.kt b/.templates/mpp_java_module/{{.module_path.lowercase()}}/src/commonMain/kotlin/PackageInfo.kt new file mode 100644 index 0000000..04b059d --- /dev/null +++ b/.templates/mpp_java_module/{{.module_path.lowercase()}}/src/commonMain/kotlin/PackageInfo.kt @@ -0,0 +1 @@ +package {{.full_module_package}} diff --git a/.templates/mpp_java_module/{{.module_path.lowercase()}}/src/jvmMain/kotlin/JvmPackageInfo.kt b/.templates/mpp_java_module/{{.module_path.lowercase()}}/src/jvmMain/kotlin/JvmPackageInfo.kt new file mode 100644 index 0000000..04b059d --- /dev/null +++ b/.templates/mpp_java_module/{{.module_path.lowercase()}}/src/jvmMain/kotlin/JvmPackageInfo.kt @@ -0,0 +1 @@ +package {{.full_module_package}} diff --git a/.templates/mpp_js_module/ModuleGenerator.json b/.templates/mpp_js_module/ModuleGenerator.json new file mode 100644 index 0000000..98a38a3 --- /dev/null +++ b/.templates/mpp_js_module/ModuleGenerator.json @@ -0,0 +1,5 @@ +{ + "module_path": "feature/sample", + "module_package": "{{.module_path.replace(\"/\", \".\")}}", + "full_module_package": "project_group.{{.module_path.replace(\"/\", \".\")}}" +} diff --git a/.templates/mpp_js_module/{{.module_path.lowercase()}}/build.gradle b/.templates/mpp_js_module/{{.module_path.lowercase()}}/build.gradle new file mode 100644 index 0000000..9676b5a --- /dev/null +++ b/.templates/mpp_js_module/{{.module_path.lowercase()}}/build.gradle @@ -0,0 +1,7 @@ +plugins { + id "org.jetbrains.kotlin.multiplatform" + id "org.jetbrains.kotlin.plugin.serialization" +} + +apply from: "$mppJsProjectPresetPath" + diff --git a/.templates/mpp_js_module/{{.module_path.lowercase()}}/src/commonMain/kotlin/PackageInfo.kt b/.templates/mpp_js_module/{{.module_path.lowercase()}}/src/commonMain/kotlin/PackageInfo.kt new file mode 100644 index 0000000..04b059d --- /dev/null +++ b/.templates/mpp_js_module/{{.module_path.lowercase()}}/src/commonMain/kotlin/PackageInfo.kt @@ -0,0 +1 @@ +package {{.full_module_package}} diff --git a/.templates/mpp_js_module/{{.module_path.lowercase()}}/src/jsMain/kotlin/JsPackageInfo.kt b/.templates/mpp_js_module/{{.module_path.lowercase()}}/src/jsMain/kotlin/JsPackageInfo.kt new file mode 100644 index 0000000..04b059d --- /dev/null +++ b/.templates/mpp_js_module/{{.module_path.lowercase()}}/src/jsMain/kotlin/JsPackageInfo.kt @@ -0,0 +1 @@ +package {{.full_module_package}} diff --git a/.templates/mpp_module/ModuleGenerator.json b/.templates/mpp_module/ModuleGenerator.json new file mode 100644 index 0000000..98a38a3 --- /dev/null +++ b/.templates/mpp_module/ModuleGenerator.json @@ -0,0 +1,5 @@ +{ + "module_path": "feature/sample", + "module_package": "{{.module_path.replace(\"/\", \".\")}}", + "full_module_package": "project_group.{{.module_path.replace(\"/\", \".\")}}" +} diff --git a/.templates/mpp_module/{{.module_path.lowercase()}}/build.gradle b/.templates/mpp_module/{{.module_path.lowercase()}}/build.gradle new file mode 100644 index 0000000..8a22926 --- /dev/null +++ b/.templates/mpp_module/{{.module_path.lowercase()}}/build.gradle @@ -0,0 +1,8 @@ +plugins { + id "org.jetbrains.kotlin.multiplatform" + id "org.jetbrains.kotlin.plugin.serialization" + id "com.android.library" +} + +apply from: "$mppProjectWithSerializationPresetPath" + diff --git a/.templates/mpp_module/{{.module_path.lowercase()}}/src/commonMain/kotlin/PackageInfo.kt b/.templates/mpp_module/{{.module_path.lowercase()}}/src/commonMain/kotlin/PackageInfo.kt new file mode 100644 index 0000000..04b059d --- /dev/null +++ b/.templates/mpp_module/{{.module_path.lowercase()}}/src/commonMain/kotlin/PackageInfo.kt @@ -0,0 +1 @@ +package {{.full_module_package}} diff --git a/.templates/mpp_module/{{.module_path.lowercase()}}/src/main/AndroidManifest.xml b/.templates/mpp_module/{{.module_path.lowercase()}}/src/main/AndroidManifest.xml new file mode 100644 index 0000000..ae51a89 --- /dev/null +++ b/.templates/mpp_module/{{.module_path.lowercase()}}/src/main/AndroidManifest.xml @@ -0,0 +1 @@ + diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index 24b3522..1e632fe 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -1,6 +1,6 @@ [versions] -kotlin = "1.8.20" +kotlin = "1.8.21" kotlin-serialization = "1.5.0" dokka = "1.8.10" @@ -13,7 +13,7 @@ espresso_core = "3.4.0" android-gradle-plugin = "7.4.2" android-minSdk = "21" android-compileSdk = "33" -android-buildTools = "33.0.1" +android-buildTools = "33.0.2" [libraries] diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index 070cb70..774fae8 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,5 +1,5 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-7.6-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-7.6.1-bin.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists