Skip to content

Create different Targets/Flavour of the same app #369

Answered by marcprux
macshodan asked this question in Q&A
Discussion options

You must be logged in to vote

Your observations are accurate: we unfortunately don't have any good way to do "flavors" of an app other than duplicating the app package. What I would recommend is putting the bulk of your app's logic in an external repository ("my-core-app") that you can add as a module dependency ("MyCoreApp") for your main app, and then have the multiple top-level app packages you create that depend on "my-core-app/MyCoreApp"). For example:

skip init --appid=com.app.id top-app TopApp:myorg/my-core-app/MyCoreApp

The top-level package in each app can vary the resources so that code in "MyCoreApp" that uses Bundle.main.url(forResource: …) to access a named resource will be getting the app-specific resou…

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@macshodan
Comment options

@marcprux
Comment options

@macshodan
Comment options

Answer selected by marcprux
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants