AppCode helper for Kotlin/Native and Xcode

Related tags

Kotlin xcode-compat
Overview

JetBrains incubator project

Kotlin Xcode compatibility Gradle plugin

The plugin is used by AppCode to set up Kotlin/Native project along with Xcode

Sources

A multi-build sample with:

  1. plugin a Gradle plugin implemented in Kotlin and taking advantage of the kotlin-dsl plugin,
  2. consumer a build that uses the Gradle plugin above.

Run with:

./gradlew consumer

This will build and publish the Gradle plugin locally ; and then run the task contributed by this plugin in the consumer build.

License

Apache 2.0. See LICENSE file in the repostiory for details

Comments
  • Changing NativeBinary.setupTask function visibility

    Changing NativeBinary.setupTask function visibility

    This is a proposal to change the NativeBinary.setupTask function visibility. Changing the visibility of this function will enable the possibility to call it from other build processes outside.

    Now it is not possible to use the setupFramework function for some cases since it will automatically find a target and use it, not enabling the possibility to use your own configured target.

    opened by Danilo-Araujo-Silva 0
  • Add iosTest task

    Add iosTest task

    This plugin currently automates one piece of common boilerplate by generating a gradle task to copy generated frameworks to xcode. Another piece of common boilerplate in Kotlin/Native iOS projects is an iosTest task, which looks something like

    task iosTest(dependsOn: 'linkDebugTestIosX64') {
        doLast {
            def testBinaryPath = kotlin.targets.iosSim.binaries.getTest('DEBUG').outputFile.absolutePath
            exec {
                commandLine 'xcrun', 'simctl', 'spawn', "iPhone Xʀ", testBinaryPath
            }
        }
    }
    

    Could this task also be generated by the plugin?

    opened by russhwolf 0
  • Configure Xcode project task

    Configure Xcode project task

    Right now it is hard to attach a K/N Framework into Xcode. Wizards to help, but probably are not enough. The idea is to create a task for the plugin. One calls it with the sourceSet name (of Kotlin/Native Framework) and the path to Xcode project. The task patches Xcode project to include the Framework. The implementation may decide automatically to use CocoaPods integration or not.

    I see the following from my own behavior:

    • I trust Xcode (only) to create a new iOS project (too many things that my go wrong)
    • I have a K/N project with the code to re-use
    • I want to try it (it should be a one-click action, not a struggle as of now)
    • I'm fine using Xcode and IntelliJ for that (my goal is to reuse code, not to try yet another IDE losing the flow)
    opened by jonnyzzz 0
  • Use same Java as in IntelliJ

    Use same Java as in IntelliJ

    It is possible to run Gradle in IntelliJ with one JRE while having the other one as default JRE on the system. Different JREs will make Gradle start several different Gradle wrappers.

    It will be better to use the same JRE as it was from IntelliJ/AndroidStudio via generating a dedicated script that is used from Xcode build

    opened by jonnyzzz 0
  • Cannot manually register framework

    Cannot manually register framework

    By default, the plugin uses Xcode environment variable to create the framework. It is hard-to-impossible to add such framework to Xcode project manually, because

    • "CONFIGURATION_BUILD_DIR" may point to sandbox folder
    • "CONFIGURATION_BUILD_DIR" may contain build target name (thus hardcoding it to Xcode project is not intended)

    Let's add an option to store frameworks under Gradle's buildDir folder instead

    opened by jonnyzzz 0
  • Project does not compile as described in README

    Project does not compile as described in README

    Running the command: $ ./gradlew consumer

    Yields the following output:

    Task :plugin FAILED

    FAILURE: Build failed with an exception.

    • What went wrong: Project directory '/XXX/kotlin-xcode-compat/plugin' is not part of the build defined by settings file '/XXX/kotlin-xcode-compat/settings.gradle.kts'. If this is an unrelated build, it must have it's own settings file.
    opened by dtornqvist 1
Owner
Kotlin
Kotlin Tools and Libraries
Kotlin
Sync Kotlin files with an Xcode project

Kotlin Xcode Sync Note Soon to be deprecated. You can add folder references instead. See here. Import kotlin files into an Xcode project. This is used

null 25 May 20, 2022
[Android Library] A SharedPreferences helper library to save and fetch the values easily.

Preference Helper A SharedPreferences helper library to save and fetch the values easily. Featured in Use in your project Add this to your module's bu

Naveen T P 13 Apr 4, 2020
TensorFlow Lite Helper for Android to help getting started with TesnorFlow.

TensorFlow Lite Helper for Android This library helps with getting started with TensorFlow Lite on Android. Inspired by TensorFlow Lite Android image

Ahmed Gamal 26 Nov 19, 2022
Android SharedPreferences Helper

PocketDB Android SharedPreferences Helper This is SharedPreferences Helper like a database noSql. Support AES encryption Latest Version Download depen

Muhammad Utsman 9 Jun 20, 2021
Run Kotlin/JS libraries in Kotlin/JVM and Kotlin/Native programs

Zipline This library streamlines using Kotlin/JS libraries from Kotlin/JVM and Kotlin/Native programs. It makes it possible to do continuous deploymen

Cash App 1.5k Dec 30, 2022
An app architecture for Kotlin/Native on Android/iOS. Use Kotlin Multiplatform Mobile.

An app architecture for Kotlin/Native on Android/iOS. Use Kotlin Multiplatform Mobile. 项目架构主要分为原生系统层、Android/iOS业务SDK层、KMM SDK层、KMM业务逻辑SDK层、iOS sdkfra

libill 4 Nov 20, 2022
A Kotlin Native program to show the time since a date, using Kotlin LibUI

TimeSince A Kotlin Native program to show the time since a date, using Kotlin LibUI Report Bug . Request Feature About The Project TimeSince is a Kotl

Russell Banks 2 May 6, 2022
The KPy gradle plugin allows you to write Kotlin/Native code and use it from python.

The KPy gradle plugin allows you to write Kotlin/Native code and use it from python.

Martmists 14 Dec 26, 2022
Ricky and Morty episode guide using KMM and Apollo GraphQL Native

Ricky And Morty Episodes - Kmm Ricky and Morty episode guide using KMM and Apollo GraphQL Native This is a simple guide on how to create an KMM projec

Julio Ribeiro 2 Apr 15, 2022
Cross-platform framework for building truly native mobile apps with Java or Kotlin. Write Once Run Anywhere support for iOS, Android, Desktop & Web.

Codename One - Cross Platform Native Apps with Java or Kotlin Codename One is a mobile first cross platform environment for Java and Kotlin developers

Codename One 1.4k Jan 9, 2023
Swift-friendly api generator for Kotlin/Native frameworks

MOKO KSwift KSwift it's gradle plugin for generation Swift-friendly API for Kotlin/Native framework. Kotlin sealed interface/class to Swift enum Kotli

IceRock Development 226 Dec 28, 2022
Native android app made with Kotlin & Compose with example usage of Ktor, SqlDelight.

Delight-Playground ?? Native Android application built with Kotlin and Jetpack Compose. This app also illustrates the usage of advance libraries such

Kasem SM 41 Nov 6, 2022
Utility - The cross-platform native Kotlin command line tool template

Utility The cross-platform native Kotlin command line tool template. Usage Make

null 0 Jan 3, 2022
Kotlin-native webserver for simple image annotations

Kotlin-native webserver for simple image annotations

null 1 Feb 26, 2022
A Kotlin library providing a simple, high-performance way to use off-heap native memory in JVM applications.

native_memory_allocator A library which uses sun.misc.Unsafe to allocate off-heap native memory. Motivation The goal of this project is to provide a s

Target 5 Dec 8, 2022
🎑 Up to date IANA timezone database library for Kotlin (JVM, JS, Native)

?? IANA Timezone Library for Kotlin Multiplatform Up to date IANA timezone database library for Kotlin (JVM, JS, Native) Usage import org.noelware.ian

Noelware 3 Jun 18, 2022
🚀 Native iOS- and Android- Apps with JavaScript

Titanium Welcome to the Titanium open source project. Titanium provides a mature platform for developers to build completely native cross-platform mob

Team Appcelerator 2.6k Jan 4, 2023
Display code with syntax highlighting :sparkles: in native way.

CodeView (Android) CodeView helps to show code content with syntax highlighting in native way. Description CodeView contains 3 core parts to implement

Kirill Biakov 827 Dec 22, 2022