Automate React Native App publishing to Google play store with Gitlab CI/CD and GPP
A step-by-step guide to automate React-Native app publishing to Google play store using Gitlab CI/CD pipeline and Gradle Play Publisher (GPP)
Introduction
Sometime back I wrote a post for Expo on how to build a React-Native app using Typescript.
Since then I have received few emails asking to write a similar guide for adding Typescript to a RN app initiated with React-Native CLI.
Also received multiple requests for some sort of write-up on how to automate release the app on Apple and Android stores.
This series is to address all those requests I have received. Its a step-by-step guide for creating a React-Native app from scratch, adding Typescript to it, publishing the app to Google Play store and finally automating the app publishing process of further releases of the app.
Why only for Google Play store, why not for Apple store?
Sorry for not including the process for publishing to Apple store. Last year, I finally stopped renewing my personal Apple developer account as I was not very happy with the fact Apple charging me for renewing my dev account every year.
Overview
In this series I would:
- initialize a new React-native app using React-native CLI
2. prepare the app for releasing to stores:
-add App Icons,
- implement Semantic versioning,
- change default created BundleID/Package name per our specifications
- setup a Gitlab project for the app’s code repository
3. add Typescript to React-native project
4. publish first release of app to Google Play store manually
- register the app on Google Play console
- create Upload key and app bundle (.aab) to upload to Google Play console
- configure a release on Google Play console and publish the app
5. automate the bundling/publishing of app to Google Play store for further releases
- Create Google Play Service account
- configure Gitlab CI/CD variables and .𝚐𝚒𝚝𝚕𝚊𝚋-𝚌𝚒.𝚢𝚖𝚕 file
- add Gradle Play Publisher (GPP) to android dependency and update 𝚋𝚞𝚒𝚕𝚍.𝚐𝚛𝚊𝚍𝚕𝚎 to automate the app bundling and publishing.
so without further due, let’s get going 🏂