Releases
Publish a Releaseβ
In order to start pushing updates, you will need to create a release.
- Android
- iOS (alpha)
shorebird release android
shorebird release ios-alpha
Creating a release builds and submits your app to Shorebird. Shorebird saves the compiled Dart code from your application in order to make updates smaller in size.
Example output:
- Android
- iOS (alpha)
$ shorebird release android
β Building release (9.6s)
β Fetching apps (0.2s)
β Detecting release version (0.2s)
β Fetching releases (68ms)
π Ready to create a new release!
π± App: new_flutter_app (7a29188a-9363-426a-9a36-74a5e166373d)
π¦ Release Version: 1.0.0+1
πΉοΈ Platform: android (arm64, arm32, x86_64)
Would you like to continue? (y/N) Yes
β Fetching Flutter revision (30ms)
β Updating release status (67ms)
β Creating artifacts (2.8s)
β Updating release status (62ms)
β
Published Release!
Your next step is to upload the app bundle to the Play Store.
build/app/outputs/bundle/release/app-release.aab
See the following link for more information:
https://support.google.com/googleplay/android-developer/answer/9859152?hl=en
$ shorebird release ios-alpha
β Fetching apps (0.2s)
β Building release (59.0s)
β Getting release version (40ms)
β Fetching releases (0.1s)
π Ready to create a new release!
π± App: My App (7a29188a-9363-426a-9a36-74a5e166373d)
π¦ Release Version: 1.0.0+1
πΉοΈ Platform: ios
Would you like to continue? (y/N) Yes
β Fetching Flutter revision (40ms)
β Creating release (0.1s)
β Creating artifacts (5.1s)
β Updating release status (57ms)
β
Published Release!
Your next step is to upload the ipa to App Store Connect.
build/ios/ipa/new_flutter_app.ipa
To upload to the App Store either:
1. Drag and drop the "build/ios/ipa/new_flutter_app.ipa" bundle into the Apple Transporter macOS app (https://apps.apple.com/us/app/transporter/id1450874784)
2. Run xcrun altool --upload-app --type ios -f build/ios/ipa/new_flutter_app.ipa --apiKey your_api_key --apiIssuer your_issuer_id.
See "man altool" for details about how to authenticate with the App Store Connect API key.
If your application supports flavors or multiple release targets, you can specify the flavor and target using the --flavor
and --target
options:
shorebird release --target ./lib/main_development.dart --flavor development
shorebird release
wraps flutter build
and can take any argument
flutter build
can. To pass arguments to the underlying flutter build
you
need to put flutter build
arguments after a --
separator. For example:
shorebird release android -- --dart-define="foo=bar"
will define the "foo"
environment
variable inside Dart as you might have done with flutter build
directly.
By default, shorebird release android
builds an AppBundle (.aab
).
If you would like to also generate an Android Package Kit (.apk
), use the
following command:
shorebird release android --artifact apk
If you would like to disable prompts and publish a release without confirmation, you can use the --force
flag. This is especially useful when using shorebird release android
in a CI environment.
shorebird release android --force
or
shorebird release ios-alpha --force
Manage Releasesβ
List Releasesβ
You can view all of your releases for your current app (as defined by your shorebird.yaml) on the Shorebird console.
Delete Releasesβ
Deleting a release will remove all associated patches and artifacts and is not reversible.
You can delete a release for your current app (as defined by your
shorebird.yaml) using shorebird releases delete
.
Example output:
$ shorebird releases delete --version 1.0.3+1
β Fetched releases. (54ms)
Are you sure you want to delete release 1.0.3+1? (y/N) Yes
β Deleted release 1.0.3+1. (0.3s)
If your application supports flavors, you can specify the flavor using the --flavor
option:
shorebird releases delete --flavor development
π² Side-loading and MDMβ
A common question we get asked, is does Shorebird require publishing to the App Store or Play Store?
No. Shorebird works fine with side-loading and mobile device management (MDM) on Android. We've not had anyone try Shorebird with iOS Developer Enterprise program, but we expect it to work just as well.
To build Shorebird for distribution via APK (e.g. side-loading), use the
--artifact
flag with the shorebird release
command. For example:
shorebird release android --artifact=apk
That will produce both .apk and .aab files. You can distribute either or both as needed.