Create A Project
Baselines projects are created with baselines_create.sh.
The generator is a shell script. It does not require Python or any project-specific generator tooling.
Requirements
You need:
- Android Studio
- Xcode
- Git
- A standard macOS/Linux shell with common Unix tools
Interactive Generation
From a workspace directory:
bash1cd ~/projects2git clone https://github.com/baselinesio/baselines-kmp.git baselines-kmp3./baselines-kmp/baselines_create.sh
The script asks for:
- package/application id, for example
com.example.myapp - app identifier, for example
MyApp - display name, for example
My App
Non-Interactive Generation
Use flags in automation or when you want a repeatable command:
bash1./baselines-kmp/baselines_create.sh \2 --package com.example.myapp \3 --name MyApp \4 --display-name "My App" \5 --output ./MyApp
What The Generator Does
The generator:
- validates package and app identifiers before writing files
- copies tracked and unignored template files
- skips local build output and machine-specific files
- replaces template package, app identifier, and display name
- moves Kotlin package directories to the new package path
- writes
.baselines/template.propertiesfor future migrations - includes
baselines_migrate.shin the generated project
Generation happens in a staging directory first. The final project directory is moved into place only after generation succeeds.
Validation
After generation:
bash1cd MyApp2./gradlew projects
Then open the Android and iOS projects:
bash1open -a "Android Studio" .2open ./app/ios/MyApp/MyApp.xcodeproj