To build a release APK for Android, follow these instructions:
You can generate a private signing key using keytool
. On Windows keytool
must be run from C:\Program Files\Java\jdkx.x.x_x\bin
.
$ keytool -genkeypair -v -keystore my-release-key.keystore -alias my-key-alias -keyalg RSA -keysize 2048 -validity 10000
This command prompts you for passwords for the keystore and key and for the Distinguished Name fields for your key. It then generates the keystore as a file called my-release-key.keystore
.
The keystore contains a single key, valid for 10000 days. The alias is a name that you will use later when signing your app, so remember to take note of the alias.
On Mac, if you're not sure where your JDK bin folder is, then perform the following command to find it:
$ /usr/libexec/java_home
It will output the directory of the JDK, which will look something like this:
/Library/Java/JavaVirtualMachines/jdkX.X.X_XXX.jdk/Contents/Home
Note: Remember to keep the keystore file private. In case you've lost upload key or it's been compromised you should follow these instructions.
- Place the
my-release-key.keystore
file under theandroid/app/
directory in your Manyverse project folder. - Edit the file
~/.gradle/gradle.properties
orandroid/gradle.properties
, and add the following (replace*****
with the correct keystore password, alias and key password),
MYAPP_RELEASE_STORE_FILE=my-upload-key.keystore
MYAPP_RELEASE_KEY_ALIAS=my-key-alias
MYAPP_RELEASE_STORE_PASSWORD=*****
MYAPP_RELEASE_KEY_PASSWORD=*****
These are going to be global Gradle variables, which we can later use in our Gradle config to sign our app.
Note about security: If you are not keen on storing your passwords in plaintext, and you are running OSX, you can also store your credentials in the Keychain Access app. Then you can skip the two last rows in ~/.gradle/gradle.properties
.
Run cd android && ./gradlew assembleRelease
(just builds the APK).
Follow this guideline strictly.
Before making official releases, you should check if the code on master
branch can appropriately build and run on all platforms, without crashing.
- Desktop: go to Manyverse's GitHub Actions and manually "run workflow" for "Preview desktop" and see if it builds
- Desktop: download one of the artifacts produced by the build above, install and run
- Android: build the APK from scratch and install on a device, or Browserstack
- iOS: build the IPA from scratch and install on a device or Browserstack
First make an Android release, then an iOS release.
- Use a computer that can build Android apps
npm run release-android
to compile the Android APKnpm run install-android-indie
to install the new APK on a device and make sure it worksgit push origin master
to update the repository
These will be built automatically by GitHub Actions and published to GitHub releases, you just need to make sure you run:
git push origin --tags
Then make an iOS release:
- Use a computer that can build iOS apps
git pull origin master
to update the repositorynpm install
andcd ios && pod install
may be needed, sometimesnpm run release-ios
to compile the iOS IPA- Once done, it should open an Organizer window where you must upload the new version to App Store
- If you want to upload to Apple, do this:
- In the Organizer, press "Distribute App"
- "App Store Connect"
- "Upload"
- Proceed as usual
- If you want to test it on BrowserStack Live, do this:
- In the Organizer, press "Distribute App"
- "App Store Connect"
- "Export"
- Proceed as usual, and at the very end, press "Export" and choose a folder
git push origin master
to update the repository
- Deploy to indie APK to GitHub releases
npm run upload-apk-gh
in the Manyverse repo (requires GitHub CLIgh
)
- Deploy indie releases on the website
npm run build
in the website reponpm run deploy
in the website repo
- Publish Android to Google Play
- Take the APK file from
android/app/build/outputs/apk/googlePlay/release
, upload and publish it on Google Play developer website
- Take the APK file from
- Publish iOS to the App Store
- Open the website and the new version should have been uploaded by now
- Don't submit the new version yet, instead, do the below
- Get the folder
e2e/apple-app-store-demo
and make it your~/.ssb
(beware to backup any existing~/.ssb
before) - Open a Manyverse desktop to use that
~/.ssb
- Create a new ssb-room server
- Put the ssb-room invite code in Manyverse desktop
- Keep this Manyverse desktop open (and the computer in non-sleep mode) for ~24 hours
- Apple's reviewers should use the ssb-room invite and will connect to your app
- Now should be safe to press submit on the App Store dashboard
- Publish Android on F-Droid:
git push origin --tags
(F-Droid server pulls our updates) - Announce on Scuttlebutt
- Run
npm run echo-ssb-post
, it shows in the terminal a ready markdown post, publish that into Scuttlebutt under the hashtag#manyverse
- Run
- Announce on Twitter
- Copy-paste from CHANGELOG.md the list of updates for the latest version, write it in the Twitter
@manyver_se
account and publish
- Copy-paste from CHANGELOG.md the list of updates for the latest version, write it in the Twitter
- Announce on Mastodon
- Copy paste from Twitter