Skip to content

Commit

Permalink
Merge pull request #52 from icerockdev/develop
Browse files Browse the repository at this point in the history
Release 0.6.0
  • Loading branch information
Alex009 committed Jun 27, 2021
2 parents eb70ce1 + 05cea92 commit bef5474
Show file tree
Hide file tree
Showing 23 changed files with 100 additions and 216 deletions.
6 changes: 2 additions & 4 deletions .github/workflows/compilation-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,12 @@ jobs:

steps:
- uses: actions/checkout@v1
- name: Set up JDK 1.8
- name: Set up JDK 11
uses: actions/setup-java@v1
with:
java-version: 1.8
java-version: 11
- name: Check plugin
run: ./gradlew -p units-generator build publishToMavenLocal
- name: Build K/N cache
run: ./gradlew :units:runCommonizer
- name: Check runtime
run: ./gradlew build publishToMavenLocal syncMultiPlatformLibraryDebugFrameworkIosX64
- name: Install pods
Expand Down
8 changes: 3 additions & 5 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,14 +21,12 @@ jobs:

steps:
- uses: actions/checkout@v1
- name: Set up JDK 1.8
- name: Set up JDK 11
uses: actions/setup-java@v1
with:
java-version: 1.8
java-version: 11
- name: Publish plugin
run: ./gradlew -p units-generator publishMavenJavaPublicationToOSSRHRepository
- name: Build K/N cache
run: ./gradlew :units:runCommonizer
- name: Publish runtime
run: ./gradlew publish
release:
Expand All @@ -44,6 +42,6 @@ jobs:
with:
commitish: ${{ github.ref }}
tag_name: release/${{ github.event.inputs.version }}
release_name: Release ${{ github.event.inputs.version }}
release_name: ${{ github.event.inputs.version }}
body: "Will be filled later"
draft: true
2 changes: 1 addition & 1 deletion MultiPlatformLibraryUnits.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |spec|
spec.name = 'MultiPlatformLibraryUnits'
spec.version = '0.5.2'
spec.version = '0.6.0'
spec.homepage = 'https://github.com/icerockdev/moko-units'
spec.source = { :git => "https://github.com/icerockdev/moko-units.git", :tag => "release/#{spec.version}" }
spec.authors = 'IceRock Development'
Expand Down
40 changes: 8 additions & 32 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,12 @@
![moko-units](img/logo.png)
[![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/units) ](https://repo1.maven.org/maven2/dev/icerock/moko/units) ![kotlin-version](https://img.shields.io/badge/kotlin-1.4.31-orange)
[![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/units) ](https://repo1.maven.org/maven2/dev/icerock/moko/units) ![kotlin-version](https://kotlin-version.aws.icerock.dev/kotlin-version?group=dev.icerock.moko&name=units)

# Mobile Kotlin units
This is a Kotlin MultiPlatform library that provides RecyclerView/UITableView/UICollectionView filling from common code.

## Table of Contents
- [Features](#features)
- [Requirements](#requirements)
- [Versions](#versions)
- [Installation](#installation)
- [Usage](#usage)
- [Samples](#samples)
Expand All @@ -20,32 +19,9 @@ This is a Kotlin MultiPlatform library that provides RecyclerView/UITableView/UI
creating from common kotlin code.

## Requirements
- Gradle version 6.0+
- Gradle version 6.8+
- Android API 16+
- iOS version 9.0+

## Versions
### Bintray
- kotlin 1.3.50
- 0.1.0
- 0.1.1
- kotlin 1.3.61
- 0.2.0
- 0.2.1
- 0.2.2
- kotlin 1.3.70
- 0.3.0
- 0.3.1
- kotlin 1.4.0
- 0.4.0
- kotlin 1.4.10
- 0.4.1
### mavenCentral
- kotlin 1.4.31
- 0.4.2
- 0.5.0
- 0.5.1
- 0.5.2
- iOS version 11.0+

## Installation
root build.gradle
Expand All @@ -56,7 +32,7 @@ buildscript {
}
dependencies {
classpath("dev.icerock.moko:units-generator:0.5.2")
classpath("dev.icerock.moko:units-generator:0.6.0")
}
}
Expand All @@ -73,10 +49,10 @@ project build.gradle
apply plugin: "dev.icerock.mobile.multiplatform-units"
dependencies {
commonMainApi("dev.icerock.moko:units:0.5.2")
commonMainImplementation("dev.icerock.moko:units-basic:0.5.2")
commonMainApi("dev.icerock.moko:units:0.6.0")
commonMainImplementation("dev.icerock.moko:units-basic:0.6.0")
commonTestImplementation("dev.icerock.moko:units-test:0.5.2")
commonTestImplementation("dev.icerock.moko:units-test:0.6.0")
}
multiplatformUnits {
Expand All @@ -88,7 +64,7 @@ multiplatformUnits {

On iOS, in addition to the Kotlin library add Pod in the Podfile.
```ruby
pod 'MultiPlatformLibraryUnits', :git => 'https://github.com/icerockdev/moko-units.git', :tag => 'release/0.5.0'
pod 'MultiPlatformLibraryUnits', :git => 'https://github.com/icerockdev/moko-units.git', :tag => 'release/0.6.0'
```
**`MultiPlatformLibraryUnits` CocoaPod requires that the framework compiled from Kotlin be named
`MultiPlatformLibrary` and be connected as a CocoaPod `MultiPlatformLibrary`.
Expand Down
6 changes: 1 addition & 5 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,6 @@ buildscript {
}
dependencies {
classpath("dev.icerock.moko:units-generator")
classpath("gradle:units-build-logic:1")
classpath(":units-build-logic")
}
}

tasks.register("clean", Delete::class).configure {
delete(rootProject.buildDir)
}
25 changes: 25 additions & 0 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
[versions]
kotlinVersion = "1.5.20"
androidGradleVersion = "4.2.1"
androidAppCompatVersion = "1.2.0"
androidCoreTestingVersion = "2.1.0"
recyclerViewVersion = "1.0.0"
kotlinPoetVersion = "1.3.0"
coroutinesVersion = "1.5.2-native-mt"
mokoGraphicsVersion = "0.7.0"
mokoResourcesVersion = "0.16.0"
mokoTestVersion = "0.4.0"
mokoUnitsVersion = "0.6.0"

[libraries]
appCompat = { module = "androidx.appcompat:appcompat", version.ref = "androidAppCompatVersion" }
recyclerView = { module = "androidx.recyclerview:recyclerview", version.ref = "recyclerViewVersion" }
coroutines = { module = "org.jetbrains.kotlinx:kotlinx-coroutines-core", version.ref = "coroutinesVersion" }
mokoGraphics = { module = "dev.icerock.moko:graphics", version.ref = "mokoGraphicsVersion" }
mokoResources = { module = "dev.icerock.moko:resources", version.ref = "mokoResourcesVersion" }
kotlinTestJUnit = { module = "org.jetbrains.kotlin:kotlin-test-junit", version.ref = "kotlinVersion" }
androidCoreTesting = { module = "androidx.arch.core:core-testing", version.ref = "androidCoreTestingVersion" }
mokoTest = { module = "dev.icerock.moko:test-core", version.ref = "mokoTestVersion" }
kotlinPoet = { module = "com.squareup:kotlinpoet", version.ref = "kotlinPoetVersion" }
androidGradlePlugin = { module = "com.android.tools.build:gradle", version.ref = "androidGradleVersion" }
javaxAnnotation = { module = "javax.annotation:jsr250-api", version = "1.0" }
2 changes: 1 addition & 1 deletion gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-6.8.3-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-7.0.2-bin.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
6 changes: 3 additions & 3 deletions sample/android-app/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ android {
}

dependencies {
implementation(Deps.Libs.Android.appCompat)
implementation(Deps.Libs.Android.recyclerView)
implementation(libs.appCompat)
implementation(libs.recyclerView)

implementation(project(":sample:mpp-library"))
implementation(projects.sample.mppLibrary)
}
7 changes: 0 additions & 7 deletions sample/build.gradle.kts

This file was deleted.

12 changes: 6 additions & 6 deletions sample/mpp-library/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,15 @@ plugins {
android.buildFeatures.dataBinding = true

dependencies {
commonMainApi(Deps.Libs.MultiPlatform.mokoUnits.common)
commonMainApi(projects.units)

androidMainImplementation(Deps.Libs.Android.recyclerView)
"androidMainImplementation"(libs.recyclerView)

// fix of package javax.annotation does not exist import javax.annotation.Generated in DataBinding code
androidMainCompileOnly("javax.annotation:jsr250-api:1.0")
"androidMainCompileOnly"(libs.javaxAnnotation)

commonTestImplementation(Deps.Libs.Tests.mokoTest)
commonTestImplementation(project(":units-test"))
commonTestImplementation(libs.mokoTest)
commonTestImplementation(projects.unitsTest)
}

multiplatformUnits {
Expand All @@ -30,5 +30,5 @@ multiplatformUnits {
}

framework {
export(project(":units"))
export(projects.units)
}
11 changes: 2 additions & 9 deletions settings.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,8 @@
* Copyright 2019 IceRock MAG Inc. Use of this source code is governed by the Apache 2.0 license.
*/

pluginManagement {
repositories {
mavenCentral()
google()

gradlePluginPortal()
}
}
enableFeaturePreview("VERSION_CATALOGS")
enableFeaturePreview("TYPESAFE_PROJECT_ACCESSORS")

dependencyResolutionManagement {
repositories {
Expand All @@ -18,7 +12,6 @@ dependencyResolutionManagement {

jcenter {
content {
includeGroup("org.jetbrains.trove4j")
includeGroup("org.jetbrains.kotlinx")
}
}
Expand Down
11 changes: 7 additions & 4 deletions units-basic/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,14 @@ plugins {
id("publication-convention")
}

group = "dev.icerock.moko"
version = libs.versions.mokoUnitsVersion.get()

dependencies {
commonMainApi(project(":units"))
commonMainApi(projects.units)

androidMainImplementation(Deps.Libs.Android.appCompat)
androidMainImplementation(libs.appCompat)

commonMainApi(Deps.Libs.MultiPlatform.mokoGraphics.common)
commonMainApi(Deps.Libs.MultiPlatform.mokoResources.common)
commonMainApi(libs.mokoGraphics)
commonMainApi(libs.mokoResources)
}
9 changes: 3 additions & 6 deletions units-build-logic/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,7 @@ repositories {
}

dependencies {
implementation("dev.icerock:mobile-multiplatform:0.9.1")
implementation("org.jetbrains.kotlin:kotlin-gradle-plugin:1.4.31")
implementation("com.android.tools.build:gradle:4.0.1")
api("dev.icerock:mobile-multiplatform:0.12.0")
api("org.jetbrains.kotlin:kotlin-gradle-plugin:1.5.20")
api("com.android.tools.build:gradle:4.2.1")
}

group = "gradle"
version = "1"
95 changes: 0 additions & 95 deletions units-build-logic/src/main/kotlin/Deps.kt

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@
import com.android.build.gradle.BaseExtension

configure<BaseExtension> {
compileSdkVersion(Deps.Android.compileSdk)
compileSdkVersion(30)

defaultConfig {
minSdkVersion(Deps.Android.minSdk)
targetSdkVersion(Deps.Android.targetSdk)
minSdkVersion(16)
targetSdkVersion(30)
}
}
Loading

0 comments on commit bef5474

Please sign in to comment.