forked from Path-Check/safeplaces-dct-app
-
Notifications
You must be signed in to change notification settings - Fork 0
82 lines (70 loc) · 2.33 KB
/
Copy pathstaging-android.yml
File metadata and controls
82 lines (70 loc) · 2.33 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
name: Staging Android
on:
push:
branches:
- develop
- master
- release-candidate
pull_request:
branches:
- develop
- master
- release-candidate
jobs:
build_staging_android:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Cache node_modules/
uses: actions/cache@v1
id: node_cache
with:
path: node_modules
key: ${{ runner.OS }}-yarn-cache-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.OS }}-yarn-cache-
- name: Install Node Dependencies
if: steps.node_cache.outputs.cache-hit != 'true'
run: yarn --frozen-lockfile
- name: Setup kernel for react native, increase watchers for release versions.
run: echo fs.inotify.max_user_watches=524288 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p
- name: Cache gradle
uses: actions/cache@v1
with:
path: ~/.gradle/caches
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*') }}
restore-keys: |
${{ runner.os }}-gradle-
- name: Set up Ruby 2.6
uses: actions/setup-ruby@v1
with:
ruby-version: 2.6
- name: Install bundler for ruby package management
run: gem install bundler -v "$(grep -A 1 "BUNDLED WITH" ./Gemfile.lock | tail -n 1)"
working-directory: ./android
- name: Cache ruby gems
uses: actions/cache@v1
id: ruby_cache
with:
path: android/vendor/bundle
key: ${{ runner.os }}-gems-${{ hashFiles('**/android/Gemfile.lock') }}
restore-keys: |
${{ runner.os }}-gems-
- name: Install Ruby Dependencies
if: steps.ruby_cache.outputs.cache-hit != 'true'
run: |
bundle config path vendor/bundle
bundle install --jobs 4 --retry 3
working-directory: ./android
- name: Build android Staging artifact
uses: maierj/fastlane-action@v1.4.0
with:
lane: 'staging'
subdirectory: 'android'
bundle-install-path: 'vendor/bundle'
- name: Upload APK
uses: actions/upload-artifact@v1
with:
name: Debug APK (Android)
path: android/app/build/outputs/apk/staging/debug/app-staging-debug.apk