Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compose Multiplatform support #35

Merged
merged 21 commits into from
Sep 6, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 0 additions & 23 deletions .github/workflows/android_build.yaml

This file was deleted.

34 changes: 0 additions & 34 deletions .github/workflows/android_tests.yaml

This file was deleted.

118 changes: 118 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,118 @@
name: Build

on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
types: [ opened, synchronize, reopened, ready_for_review ]

concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true

jobs:
buildAndroid:
name: Build Android
runs-on: ubuntu-latest
if: github.event.pull_request.draft == false

steps:
# Code checkout
- name: Checkout code
id: checkout_code
uses: actions/checkout@v4

# Setup Java and Gradle
- name: Java and Gradle set up
uses: ./.github/workflows/setup/java-setup

# Grant execute permission for script
- name: Grant execute permission for script
id: grant_script_permission
shell: bash
run: chmod +x ./scripts/build_android.sh

# Build and verify Android
- name: Build and verify Android
run: ./scripts/build_android.sh

buildiOS:
name: Build iOS
runs-on: macos-latest
if: github.event.pull_request.draft == false

steps:
# Code checkout
- name: Checkout code
id: checkout_code
uses: actions/checkout@v4

# Setup Java and Gradle
- name: Java and Gradle set up
uses: ./.github/workflows/setup/java-setup

# Grant execute permission for script
- name: Grant execute permission for script
id: grant_script_permission
shell: bash
run: chmod +x ./scripts/build_android.sh

# Setup iOS
- name: iOS set up
uses: ./.github/workflows/setup/ios-setup

# Build iOS app
- name: Build iOS app
id: build_ios_debug
run: xcodebuild build -workspace sample/iosApp/iosApp.xcworkspace -configuration Debug -scheme iosApp -sdk iphonesimulator -verbose

buildWeb:
name: Build Web
runs-on: ubuntu-latest
if: github.event.pull_request.draft == false

steps:
# Code checkout
- name: Checkout code
id: checkout_code
uses: actions/checkout@v4

# Setup Java and Gradle
- name: Java and Gradle set up
uses: ./.github/workflows/setup/java-setup

# Grant execute permission for script
- name: Grant execute permission for script
id: grant_script_permission
shell: bash
run: chmod +x ./scripts/build_web.sh

# Build and verify Web
- name: Build and verify Web
run: ./scripts/build_web.sh

buildMacOS:
name: Build MacOS
runs-on: macos-latest
if: github.event.pull_request.draft == false

steps:
# Code checkout
- name: Checkout code
id: checkout_code
uses: actions/checkout@v4

# Setup Java and Gradle
- name: Java and Gradle set up
uses: ./.github/workflows/setup/java-setup

# Grant execute permission for script
- name: Grant execute permission for script
id: grant_script_permission
shell: bash
run: chmod +x ./scripts/build_macos.sh

# Build and verify MacOS
- name: Build and verify MacOS
run: ./scripts/build_macos.sh
18 changes: 18 additions & 0 deletions .github/workflows/setup/ios-setup/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: iOS set up
description: Sets up Kotlin Native and Cocoapods
runs:
using: "composite"
steps:
- shell: bash
run: ./gradlew :sample:composeApp:generateDummyFramework

- name: Set up cocoapods
uses: maxim-lobanov/setup-cocoapods@v1
with:
version: latest

- shell: bash
name: Install Dependencies
run: |
cd sample/iosApp
pod install --verbose
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: Android and Gradle Job Setup
description: Sets up Android and Gradle
name: Java and Gradle Job Setup
description: Sets up Java and Gradle
runs:
using: "composite"
steps:
Expand All @@ -8,7 +8,7 @@ runs:
id: setup_jdk
uses: actions/setup-java@v4
with:
distribution: "zulu"
distribution: "corretto"
java-version: 17

# Grant execute permission for gradlew
Expand All @@ -27,4 +27,9 @@ runs:
~/.gradle/wrapper
key: ${{ runner.os }}-${{ hashFiles('**/*.gradle*') }}-${{ hashFiles('**/gradle/wrapper/gradle-wrapper.properties') }}-${{ hashFiles('**/buildSrc/**/*.kt') }}
restore-keys: |
${{ runner.os }}-gradle-
${{ runner.os }}-gradle-

# Setup Gradle
- name: Set up Gradle
id: set_up_gradle
uses: gradle/actions/setup-gradle@v4
8 changes: 6 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,12 @@
# Java class files
*.class

# Kotlin libraries
.kotlin/

app/
distributions/

# Generated files
bin/
gen/
Expand Down Expand Up @@ -41,8 +47,6 @@ captures/
*.iml
.idea/

.kotlin/

# Keystore files
# Uncomment the following lines if you do not want to check your keystore files in.
#*.jks
Expand Down
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
# JetLime 🍋

> A simple yet highly customizable library for showing a TimeLine interface in Jetpack Compose.
> A simple yet highly customizable library for showing a TimeLine interface in Compose Multiplatform.

[![Compose Compiler](https://img.shields.io/badge/Compose%20Compiler-1.5.15-blue?style=for-the-badge&logo=appveyor)](https://developer.android.com/jetpack/androidx/releases/compose)
![Kotlin](https://img.shields.io/badge/Kotlin-1.9.25-blue.svg?color=blue&style=for-the-badge)
![Kotlin](https://img.shields.io/badge/Kotlin-2.0.20-blue.svg?color=blue&style=for-the-badge)
[![Maven Central](https://img.shields.io/maven-central/v/io.github.pushpalroy/jetlime?style=for-the-badge&logo=appveyor)](https://search.maven.org/artifact/io.github.pushpalroy/jetlime)
![Stars](https://img.shields.io/github/stars/pushpalroy/jetlime?color=yellowgreen&style=for-the-badge)
![Forks](https://img.shields.io/github/forks/pushpalroy/jetlime?color=yellowgreen&style=for-the-badge)
Expand Down Expand Up @@ -32,7 +32,7 @@ In `build.gradle` of app module, include the following dependency

```gradle
dependencies {
implementation("io.github.pushpalroy:jetlime:2.3.0")
implementation("io.github.pushpalroy:jetlime:3.0.0")
}
```

Expand Down
2 changes: 0 additions & 2 deletions app/.gitignore

This file was deleted.

96 changes: 0 additions & 96 deletions app/build.gradle.kts

This file was deleted.

21 changes: 0 additions & 21 deletions app/proguard-rules.pro

This file was deleted.

Loading
Loading