Skip to content

Commit

Permalink
Chore: Updated Fastlane and CI for release
Browse files Browse the repository at this point in the history
This commit adds Fastlane for automating the Android release process and configures CI for internal, beta, and production releases using GitHub Actions.

The following changes were made:

- Added Fastlane configuration files for building, testing, and deploying the app.
- Added GitHub Actions workflows for triggering internal, beta, and production releases.
- Updated .gitignore to exclude Fastlane report files.
- Updated dependency versions in Gemfile.lock.
- Added a README for Fastlane.
- Updated the make_site workflow to trigger on released releases instead of published releases.
  • Loading branch information
niyajali committed Nov 21, 2024
1 parent 2bd59c3 commit 5e34e8b
Show file tree
Hide file tree
Showing 6 changed files with 101 additions and 28 deletions.
7 changes: 7 additions & 0 deletions .github/workflows/internal_or_beta_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,12 @@ on:
- internal
- beta

publish_to_play_store:
required: false
default: false
description: Publish to Play Store?
type: boolean

env:
SUPPLY_UPLOAD_MAX_RETRIES: 5

Expand Down Expand Up @@ -137,6 +143,7 @@ jobs:

play_publish:
name: Play Publish
if: ${{ inputs.publish_to_play_store == true }}
runs-on: ubuntu-latest
concurrency:
group: playstore_deploy
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/make_site.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ on:
branches: [ "dev" ]
# Trigger on new releases
release:
types: [ published ]
types: [ released ]
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:

Expand Down
7 changes: 2 additions & 5 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,6 @@ build/
!/.idea/codeStyles/Project.xml
!/.idea/codeStyles/codeStyleConfig.xml

# Gradle cache
.gradle

# Kotlin
.kotlin

Expand All @@ -54,12 +51,12 @@ app/app.iml
app/manifest-merger-release-report.txt

# Exclude Google services from prod flavour
mifospay/src/prod/google-services.json
mifospay-android/src/prod/google-services.json

#*.keystore

version.txt

fastlane/report.xml
firebaseAppDistributionServiceCredentialsFile.json
playStorePublishServiceCredentialsFile.json

Expand Down
47 changes: 25 additions & 22 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -10,20 +10,20 @@ GEM
artifactory (3.0.17)
atomos (0.1.3)
aws-eventstream (1.3.0)
aws-partitions (1.971.0)
aws-sdk-core (3.203.0)
aws-partitions (1.1011.0)
aws-sdk-core (3.213.0)
aws-eventstream (~> 1, >= 1.3.0)
aws-partitions (~> 1, >= 1.651.0)
aws-partitions (~> 1, >= 1.992.0)
aws-sigv4 (~> 1.9)
jmespath (~> 1, >= 1.6.1)
aws-sdk-kms (1.89.0)
aws-sdk-core (~> 3, >= 3.203.0)
aws-sdk-kms (1.96.0)
aws-sdk-core (~> 3, >= 3.210.0)
aws-sigv4 (~> 1.5)
aws-sdk-s3 (1.160.0)
aws-sdk-core (~> 3, >= 3.203.0)
aws-sdk-s3 (1.172.0)
aws-sdk-core (~> 3, >= 3.210.0)
aws-sdk-kms (~> 1)
aws-sigv4 (~> 1.5)
aws-sigv4 (1.9.1)
aws-sigv4 (1.10.1)
aws-eventstream (~> 1, >= 1.0.2)
babosa (1.0.4)
base64 (0.2.0)
Expand All @@ -38,8 +38,8 @@ GEM
domain_name (0.6.20240107)
dotenv (2.8.1)
emoji_regex (3.2.3)
excon (0.111.0)
faraday (1.10.3)
excon (0.112.0)
faraday (1.10.4)
faraday-em_http (~> 1.0)
faraday-em_synchrony (~> 1.0)
faraday-excon (~> 1.1)
Expand All @@ -65,10 +65,10 @@ GEM
faraday-patron (1.0.0)
faraday-rack (1.0.0)
faraday-retry (1.0.3)
faraday_middleware (1.2.0)
faraday_middleware (1.2.1)
faraday (~> 1.0)
fastimage (2.3.1)
fastlane (2.222.0)
fastlane (2.225.0)
CFPropertyList (>= 2.3, < 4.0.0)
addressable (>= 2.8, < 3.0.0)
artifactory (~> 3.0)
Expand All @@ -84,6 +84,7 @@ GEM
faraday-cookie_jar (~> 0.0.6)
faraday_middleware (~> 1.0)
fastimage (>= 2.1.0, < 3.0.0)
fastlane-sirp (>= 1.0.0)
gh_inspector (>= 1.1.2, < 2.0.0)
google-apis-androidpublisher_v3 (~> 0.3)
google-apis-playcustomapp_v1 (~> 0.1)
Expand All @@ -110,6 +111,8 @@ GEM
xcpretty (~> 0.3.0)
xcpretty-travis-formatter (>= 0.0.3, < 2.0.0)
fastlane-plugin-increment_version_code (0.4.3)
fastlane-sirp (1.0.0)
sysrandom (~> 1.0)
gh_inspector (1.1.3)
google-apis-androidpublisher_v3 (0.54.0)
google-apis-core (>= 0.11.0, < 2.a)
Expand Down Expand Up @@ -152,17 +155,17 @@ GEM
domain_name (~> 0.5)
httpclient (2.8.3)
jmespath (1.6.2)
json (2.7.2)
jwt (2.8.2)
json (2.8.2)
jwt (2.9.3)
base64
mini_magick (4.13.2)
mini_mime (1.1.5)
multi_json (1.15.0)
multipart-post (2.4.1)
nanaimo (0.3.0)
nanaimo (0.4.0)
naturally (2.2.1)
nkf (0.2.0)
optparse (0.5.0)
optparse (0.6.0)
os (1.1.4)
plist (3.7.1)
public_suffix (6.0.1)
Expand All @@ -172,7 +175,7 @@ GEM
trailblazer-option (>= 0.1.1, < 0.2.0)
uber (< 0.2.0)
retriable (3.1.2)
rexml (3.3.7)
rexml (3.3.9)
rouge (2.0.7)
ruby2_keywords (0.0.5)
rubyzip (2.3.2)
Expand All @@ -185,6 +188,7 @@ GEM
simctl (1.6.10)
CFPropertyList
naturally
sysrandom (1.0.5)
terminal-notifier (2.0.0)
terminal-table (3.0.2)
unicode-display_width (>= 1.1.1, < 3)
Expand All @@ -194,15 +198,15 @@ GEM
tty-spinner (0.9.3)
tty-cursor (~> 0.7)
uber (0.1.0)
unicode-display_width (2.5.0)
unicode-display_width (2.6.0)
word_wrap (1.0.0)
xcodeproj (1.25.0)
xcodeproj (1.27.0)
CFPropertyList (>= 2.3.3, < 4.0)
atomos (~> 0.1.3)
claide (>= 1.0.2, < 2.0)
colored2 (~> 3.1)
nanaimo (~> 0.3.0)
rexml (>= 3.3.2, < 4.0)
nanaimo (~> 0.4.0)
rexml (>= 3.3.6, < 4.0)
xcpretty (0.3.0)
rouge (~> 2.0.7)
xcpretty-travis-formatter (1.0.1)
Expand All @@ -213,7 +217,6 @@ PLATFORMS
x64-mingw-ucrt
x86_64-linux


DEPENDENCIES
fastlane
fastlane-plugin-increment_version_code
Expand Down
48 changes: 48 additions & 0 deletions fastlane/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
fastlane documentation
----

# Installation

Make sure you have the latest version of the Xcode command line tools installed:

```sh
xcode-select --install
```

For _fastlane_ installation instructions, see [Installing _fastlane_](https://docs.fastlane.tools/#installing-fastlane)

# Available Actions

## Android

### android deploy_internal

```sh
[bundle exec] fastlane android deploy_internal
```

Deploy internal tracks to Google Play

### android promote_to_beta

```sh
[bundle exec] fastlane android promote_to_beta
```

Promote internal tracks to beta on Google Play

### android promote_to_production

```sh
[bundle exec] fastlane android promote_to_production
```

Promote beta tracks to production on Google Play

----

This README.md is auto-generated and will be re-generated every time [_fastlane_](https://fastlane.tools) is run.

More information about _fastlane_ can be found on [fastlane.tools](https://fastlane.tools).

The documentation of _fastlane_ can be found on [docs.fastlane.tools](https://docs.fastlane.tools).
18 changes: 18 additions & 0 deletions fastlane/report.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
<?xml version="1.0" encoding="UTF-8"?>
<testsuites>
<testsuite name="fastlane.lanes">




<testcase classname="fastlane.lanes" name="0: default_platform" time="0.001823">

</testcase>


<testcase classname="fastlane.lanes" name="1: versionFile" time="42.258112">

</testcase>

</testsuite>
</testsuites>

0 comments on commit 5e34e8b

Please sign in to comment.