Skip to content
This repository was archived by the owner on Sep 8, 2025. It is now read-only.

Commit 6d49562

Browse files
authored
Merge pull request #297 from anton6tak/#294-update-to-kotlin1.5.20-gradle-7.0.2
#294 gradle 7.0.2 kotlin 1.5.20, convention-plugin
2 parents b6c1fea + b675ee3 commit 6d49562

File tree

205 files changed

+1079
-1178
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

205 files changed

+1079
-1178
lines changed

.github/workflows/compilation-check.yml

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,15 +12,18 @@ jobs:
1212

1313
steps:
1414
- uses: actions/checkout@v1
15-
- name: Set up JDK 1.8
15+
- name: Set up JDK 11
1616
uses: actions/setup-java@v1
1717
with:
18-
java-version: 1.8
18+
java-version: 11
1919
- name: Cocoapods install
2020
run: (cd sample/ios-app && pod install)
2121
- name: Check build
22-
run: ./gradlew build
22+
run: ./gradlew build publishToMavenLocal syncMultiPlatformLibraryDebugFrameworkIosX64
2323
- name: Check plugin publication
2424
run: ./gradlew -p plugin publishToMavenLocal
25-
- name: Check runtime publication
26-
run: ./gradlew publishToMavenLocal
25+
- name: Install pods with kotlin
26+
run: cd sample/ios-app && pod install
27+
- name: build ios sample
28+
run: cd sample/ios-app && set -o pipefail && xcodebuild -scheme TestProj -workspace TestProj.xcworkspace -configuration Debug -sdk iphonesimulator -arch x86_64 build CODE_SIGNING_REQUIRED=NO CODE_SIGNING_ALLOWED=NO | xcpretty
29+

.github/workflows/publish-dev.yml

Lines changed: 0 additions & 33 deletions
This file was deleted.

.github/workflows/publish.yml

Lines changed: 38 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,48 @@
1-
name: KMP library publish production version
1+
name: Create release
22

33
on:
4-
release:
5-
types: [published]
4+
workflow_dispatch:
5+
inputs:
6+
version:
7+
description: 'Version'
8+
default: '0.1.0'
9+
required: true
610

711
jobs:
8-
build:
12+
publish:
13+
name: Publish library at mavenCentral
914
runs-on: macOS-latest
15+
env:
16+
OSSRH_USER: ${{ secrets.OSSRH_USER }}
17+
OSSRH_KEY: ${{ secrets.OSSRH_KEY }}
18+
SIGNING_KEY_ID: ${{ secrets.SIGNING_KEYID }}
19+
SIGNING_PASSWORD: ${{ secrets.SIGNING_PASSWORD }}
20+
SIGNING_KEY: ${{ secrets.GPG_KEY_CONTENTS }}
1021

1122
steps:
1223
- uses: actions/checkout@v1
13-
- name: Set up JDK 1.8
24+
- name: Set up JDK 11
1425
uses: actions/setup-java@v1
1526
with:
16-
java-version: 1.8
17-
- name: Cocoapods install
18-
run: (cd sample/ios-app && pod install)
19-
- name: Plugin publication
20-
run: |
21-
./gradlew -p plugin \
22-
publishNoValidationToBintray \
23-
-DBINTRAY_USER=${{ secrets.BINTRAY_USER }} -DBINTRAY_KEY=${{ secrets.BINTRAY_KEY }} \
24-
--stacktrace
25-
- name: Runtime publication
26-
run: |
27-
./gradlew \
28-
publishNoValidationToBintray \
29-
-DBINTRAY_USER=${{ secrets.BINTRAY_USER }} -DBINTRAY_KEY=${{ secrets.BINTRAY_KEY }} \
30-
--stacktrace
27+
java-version: 11
28+
- name: Publish plugin
29+
run: ./gradlew -p plugin publishMavenJavaPublicationToOSSRHRepository
30+
- name: Publish library
31+
run: ./gradlew publish
32+
33+
release:
34+
name: Create release
35+
needs: publish
36+
runs-on: ubuntu-latest
37+
steps:
38+
- name: Create Release
39+
id: create_release
40+
uses: actions/create-release@v1
41+
env:
42+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
43+
with:
44+
commitish: ${{ github.ref }}
45+
tag_name: release/${{ github.event.inputs.version }}
46+
release_name: ${{ github.event.inputs.version }}
47+
body: "Will be filled later"
48+
draft: true

README.md

Lines changed: 7 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,10 @@
11
![moko-widgets](https://user-images.githubusercontent.com/5010169/70204294-93a45900-1752-11ea-9bb6-820d514ceef9.png)
2-
[![GitHub license](https://img.shields.io/badge/license-Apache%20License%202.0-blue.svg?style=flat)](http://www.apache.org/licenses/LICENSE-2.0) [![Download](https://api.bintray.com/packages/icerockdev/moko/moko-widgets/images/download.svg) ](https://bintray.com/icerockdev/moko/moko-widgets/_latestVersion) ![kotlin-version](https://img.shields.io/badge/kotlin-1.3.70-orange)
2+
[![GitHub license](https://img.shields.io/badge/license-Apache%20License%202.0-blue.svg?style=flat)](http://www.apache.org/licenses/LICENSE-2.0) [![Download](https://img.shields.io/maven-central/v/dev.icerock.moko/moko-widgets) ](https://repo1.maven.org/maven2/dev/icerock/moko/moko-widgets) ![kotlin-version](https://kotlin-version.aws.icerock.dev/kotlin-version?group=dev.icerock.moko&name=widgets)
33

44
# Mobile Kotlin widgets
55
This is a Kotlin MultiPlatform library that provides declarative UI and application screens management
66
in common code. You can implement full application for Android and iOS only from common code with it.
77

8-
## Current status
9-
Current version - `0.1.0-dev-19`. Dev version is not tested in production tasks yet, API can be changed and
10-
bugs may be found. But dev version is chance to test limits of API and concepts to feedback and improve lib.
11-
We open for any feedback and ideas (go to issues or #moko at [kotlinlang.slack.com](https://kotlinlang.slack.com))!
12-
13-
## Roadmap
14-
- December-January: Test library in real project;
15-
- February: production usage at IceRock;
16-
- March: 0.1.0 release with flexible API;
17-
- First half of 2020: more widgets, more factories; figma template and generation of screens.
18-
198
## Sample Screen
209
|Android|iOS|
2110
|---|---|
@@ -200,49 +189,24 @@ val loginScreen = Theme(baseTheme) {
200189
- **reactive data handling**.
201190

202191
## Requirements
203-
- Gradle version 5.6.4+
192+
- Gradle version 6.8+
204193
- Android API 16+
205-
- iOS version 9.0+
206-
207-
## Versions
208-
- kotlin 1.3.50
209-
- 0.1.0-dev-1
210-
- kotlin 1.3.60
211-
- 0.1.0-dev-2
212-
- 0.1.0-dev-3
213-
- 0.1.0-dev-4
214-
- 0.1.0-dev-5
215-
- kotlin 1.3.61
216-
- 0.1.0-dev-6
217-
- 0.1.0-dev-7
218-
- 0.1.0-dev-8
219-
- 0.1.0-dev-9
220-
- 0.1.0-dev-10
221-
- 0.1.0-dev-11
222-
- 0.1.0-dev-12
223-
- 0.1.0-dev-13
224-
- 0.1.0-dev-14
225-
- 0.1.0-dev-15
226-
- kotlin 1.3.70
227-
- 0.1.0-dev-16
228-
- 0.1.0-dev-17
229-
- 0.1.0-dev-18
230-
- 0.1.0-dev-19
194+
- iOS version 11.0+
231195

232196
## Installation
233197
root build.gradle
234198
```groovy
235199
allprojects {
236200
repositories {
237-
maven { url = "https://dl.bintray.com/icerockdev/moko" }
201+
mavenCentral()
238202
}
239203
}
240204
```
241205

242206
project build.gradle
243207
```groovy
244208
dependencies {
245-
commonMainApi("dev.icerock.moko:widgets:0.1.0-dev-19")
209+
classpath("dev.icerock.moko:widgets:0.1.0")
246210
}
247211
```
248212

@@ -251,11 +215,11 @@ root build.gradle
251215
```groovy
252216
buildscript {
253217
repositories {
254-
maven { url = "https://dl.bintray.com/icerockdev/plugins" } // gradle plugin
218+
mavenCentral()
255219
}
256220
257221
dependencies {
258-
classpath "dev.icerock.moko.widgets:gradle-plugin:0.1.0-dev-19"
222+
classpath "dev.icerock.moko.widgets:gradle-plugin:0.1.0"
259223
}
260224
}
261225

build.gradle.kts

Lines changed: 7 additions & 80 deletions
Original file line numberDiff line numberDiff line change
@@ -4,36 +4,20 @@
44

55
buildscript {
66
repositories {
7-
jcenter()
7+
mavenCentral()
88
google()
9-
10-
maven { url = uri("https://dl.bintray.com/kotlin/kotlin") }
11-
maven { url = uri("https://kotlin.bintray.com/kotlinx") }
12-
maven { url = uri("https://plugins.gradle.org/m2/") }
13-
maven { url = uri("https://dl.bintray.com/icerockdev/plugins") }
9+
gradlePluginPortal()
10+
jcenter()
1411
}
1512
dependencies {
16-
classpath("dev.icerock.moko:resources-generator:0.13.2")
17-
classpath("dev.icerock.moko.widgets:gradle-plugin:0.1.0-dev-21")
18-
classpath("gradle:moko-widgets-deps:1")
13+
classpath("dev.icerock.moko:resources-generator:0.16.1")
14+
classpath("dev.icerock.moko.widgets:gradle-plugin")
15+
16+
classpath(":widgets-build-logic")
1917
}
2018
}
2119

2220
allprojects {
23-
repositories {
24-
google()
25-
jcenter()
26-
27-
maven { url = uri("https://kotlin.bintray.com/kotlin") }
28-
maven { url = uri("https://kotlin.bintray.com/kotlinx") }
29-
maven { url = uri("https://dl.bintray.com/icerockdev/moko") }
30-
maven { url = uri("https://dl.bintray.com/icerockdev/plugins") }
31-
maven { url = uri("http://dl.bintray.com/lukaville/maven") }
32-
33-
maven { url = uri("https://dl.bintray.com/icerockdev/moko-dev") }
34-
maven { url = uri("https://dl.bintray.com/icerockdev/plugins-dev") }
35-
}
36-
3721
configurations
3822
.matching { it.name == "compileOnly" }
3923
.configureEach {
@@ -42,63 +26,6 @@ allprojects {
4226
"compileOnly"("javax.annotation:jsr250-api:1.0")
4327
}
4428
}
45-
46-
configurations.all {
47-
resolutionStrategy.dependencySubstitution {
48-
substitute(module("com.nbsp:library"))
49-
.using(module("com.nbsp:materialfilepicker:1.9.1"))
50-
.because("androidx support in new artifact")
51-
}
52-
}
53-
54-
plugins.withType<com.android.build.gradle.LibraryPlugin> {
55-
configure<com.android.build.gradle.LibraryExtension> {
56-
compileSdkVersion(Deps.Android.compileSdk)
57-
58-
defaultConfig {
59-
minSdkVersion(Deps.Android.minSdk)
60-
targetSdkVersion(Deps.Android.targetSdk)
61-
}
62-
}
63-
}
64-
65-
val project = this
66-
val bintrayPath: Pair<String, String>?
67-
when {
68-
this.name.startsWith("widgets") -> {
69-
bintrayPath = "moko" to "moko-widgets"
70-
71-
this.group = "dev.icerock.moko"
72-
this.version = Deps.mokoWidgetsVersion
73-
}
74-
else -> {
75-
bintrayPath = null
76-
}
77-
}
78-
79-
if (bintrayPath != null) {
80-
project.plugins.withType<MavenPublishPlugin> {
81-
project.configure<PublishingExtension> {
82-
val repo = bintrayPath.first
83-
val artifact = bintrayPath.second
84-
val isDevPublish = project.properties.containsKey("devPublish")
85-
val fullRepoName = if (isDevPublish) "$repo-dev" else repo
86-
val mavenUrl =
87-
"https://api.bintray.com/maven/icerockdev/$fullRepoName/$artifact/;publish=1"
88-
89-
repositories.maven(mavenUrl) {
90-
this.name = "bintray"
91-
92-
credentials {
93-
username = System.getProperty("BINTRAY_USER")
94-
password = System.getProperty("BINTRAY_KEY")
95-
}
96-
}
97-
}
98-
}
99-
100-
apply<dev.icerock.moko.widgets.gradle.BintrayPublishingPlugin>()
101-
}
10229
}
10330

10431
tasks.register("clean", Delete::class).configure {

gradle.properties

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,11 @@ org.gradle.parallel=true
44

55
kotlin.code.style=official
66

7-
android.useAndroidX=true
7+
kotlin.native.enableDependencyPropagation=false
8+
kotlin.mpp.enableGranularSourceSetsMetadata=true
9+
kotlin.mpp.enableCompatibilityMetadataVariant=true
810

9-
# Workaround for Bintray treating .sha512 files as artifacts
10-
# https://github.com/gradle/gradle/issues/11412
11-
systemProp.org.gradle.internal.publish.checksums.insecure=true
11+
android.useAndroidX=true
1212

1313
mobile.multiplatform.useIosShortcut=false
1414
mobile.multiplatform.iosTargetWarning=false

0 commit comments

Comments
 (0)