joreilly / PeopleInSpace

Kotlin Multiplatform sample with SwiftUI, Jetpack Compose, Compose for Wear, Compose for Desktop, and Compose for Web clients along with Ktor backend.
Apache License 2.0
2.91k stars 259 forks source link

Refactor for project clone #29

Open burnhamd opened 3 years ago

burnhamd commented 3 years ago

This is one of the best examples of getting started with a KMM project and the only example Ive seen that uses SwiftUI and jetpack compose.

It would be great if there was a refactor guide on how to migrate to a new project/package names

miduch commented 3 years ago

any plans to update project to use SwiftUI 2 (from swiftUI app using SceneDelegate to the new @main App protocol)?

joreilly commented 3 years ago

Yeah, definitely something I'd hoped to do. Also open to PRs :)

joreilly commented 3 years ago

@burnhamd sorry, meant to respond to this before. So, I did update settings for this (and other repos) the other day to be a "Template repository" but still needs more updates to allow as you migration to different project/package name.

RdeWilde commented 3 years ago

I'm also looking for a smooth way to do this. Basically I'd like to start of multiple projects from the same base, and merge new update back into it. Now sure what structure would be best. I was thinking to keep platform-specific boilerplate code, and base the project-specific implementation in a subproject of it? That way I hope I can use keep the base projects up to date, and not having to do it on a per-project base.

But I'm only just getting started, thus very interested in other perspectives

RdeWilde commented 3 years ago

@burnhamd sorry, meant to respond to this before. So, I did update settings for this (and other repos) the other day to be a "Template repository" but still needs more updates to allow as you migration to different project/package name.

While using it as a template is a great idea, i experienced at least one caveat, which is that you can merge from and to another.

$ git pull joreilly main
From github.com:joreilly/PeopleInSpace
 * branch            main       -> FETCH_HEAD
fatal: refusing to merge unrelated histories

It seems to create a whole new repo.