Skip to content

Commit 0a67402

Browse files
Merge pull request #26 from rootstrap/chore/eas
Eas build --local
2 parents 393ddbb + b1fbfab commit 0a67402

File tree

9 files changed

+425
-266
lines changed

9 files changed

+425
-266
lines changed

.github/workflows/expo-doctor.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,13 @@ jobs:
2828
name: Expo Doctor (expo)
2929
runs-on: ubuntu-latest
3030

31+
env:
32+
# Add your other environment variables here, e.g.:
33+
API_URL: https://dummyjson.com/
34+
SECRET_KEY: my-secret-key
35+
VAR_NUMBER: 10
36+
VAR_BOOL: true
37+
3138
steps:
3239
- name: 📦 Checkout project repo
3340
uses: actions/checkout@v3

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,8 @@ yarn-error.log
2222

2323
# macOS
2424
.DS_Store
25+
*.apk
26+
*.ipa
2527

2628

2729
# @generated expo-cli sync-2b81b286409207a5da26e14c78851eb30d8ccbdb

README-project.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,10 @@ To run the app on Android
3737
pnpm android
3838
```
3939

40+
To build your app locally you can run any of the build scripts with --local.
41+
42+
`pnpm build:development:ios --local`
43+
4044
### SonarQube setup
4145

4246
SonarQube is an open-source platform for continuous inspection of code quality. It performs automatic reviews to detect bugs, code smells, and security vulnerabilities. Rootstrap has a SonarQube instance to improve the quality of the software we develop. On each PR, a GitHub Action is triggered to perform the analysis. To set up SonarQube correctly, you need to add the `SONAR_TOKEN`, `SONAR_URL`, and `SONAR_PROJECT` secrets to the repository. Additionally, you must select the quality gate named `ReactNativeTemplate` for your project on SonarQube. In case you're using this project outside Rootstrap and you're not planning to use SonarQube the sonar scanner [workflow](.github/workflows/sonar.yml) should be deleted.

app.config.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ export default ({ config }: ConfigContext): ExpoConfig => ({
99
description: `${Env.NAME} Mobile App`,
1010
owner: Env.EXPO_ACCOUNT_OWNER,
1111
scheme: Env.SCHEME,
12-
slug: 'obytesapp',
12+
slug: 'reactnativetemplate',
1313
version: Env.VERSION.toString(),
1414
orientation: 'portrait',
1515
icon: './assets/icon.png',
@@ -21,6 +21,10 @@ export default ({ config }: ConfigContext): ExpoConfig => ({
2121
},
2222
updates: {
2323
fallbackToCacheTimeout: 0,
24+
url: 'https://u.expo.dev/72fdf440-59f1-493d-96e3-4afad8d7a045',
25+
},
26+
runtimeVersion: {
27+
policy: 'appVersion',
2428
},
2529
assetBundlePatterns: ['**/*'],
2630
ios: {

eas.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,6 @@
4040
"EXPO_NO_DOTENV": "1",
4141
"FLIPPER_DISABLE": "1"
4242
},
43-
4443
"prebuildCommand": "prebuild --skip-dependency-update react",
4544
"cache": {
4645
"key": "eas-1"
@@ -60,11 +59,11 @@
6059
"APP_ENV": "development",
6160
"EXPO_NO_DOTENV": "1"
6261
},
63-
6462
"prebuildCommand": "prebuild --skip-dependency-update react",
6563
"cache": {
6664
"key": "eas-1"
67-
}
65+
},
66+
"channel": "development"
6867
},
6968
"simulator": {
7069
"ios": {
@@ -82,7 +81,8 @@
8281
"prebuildCommand": "prebuild --skip-dependency-update react",
8382
"cache": {
8483
"key": "eas-1"
85-
}
84+
},
85+
"channel": "simulator"
8686
}
8787
},
8888
"submit": {

env.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,9 +36,9 @@ require('dotenv').config({
3636
const BUNDLE_ID = 'com.rootstrap'; // ios bundle id
3737
const PACKAGE = 'com.rootstrap'; // android package name
3838
const NAME = 'RootstrapApp'; // app name
39-
const EXPO_ACCOUNT_OWNER = 'rootstrap'; // expo account owner
40-
const EAS_PROJECT_ID = 'c3e1075b-6fe7-4686-aa49-35b46a229044'; // eas project id
41-
const SCHEME = 'rootstrapApp'; // app scheme
39+
const EXPO_ACCOUNT_OWNER = 'rsdevs'; // expo account owner
40+
const EAS_PROJECT_ID = '72fdf440-59f1-493d-96e3-4afad8d7a045'; // eas project id
41+
const SCHEME = 'RootstrapApp'; // app scheme
4242

4343
/**
4444
* We declare a function withEnvSuffix that will add a suffix to the variable name based on the APP_ENV

package.json

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,8 @@
2222
"build:development:android": "cross-env APP_ENV=development EXPO_NO_DOTENV=1 eas build --profile development --platform android ",
2323
"build:staging:ios": "cross-env APP_ENV=staging EXPO_NO_DOTENV=1 eas build --profile staging --platform ios",
2424
"build:staging:android": "cross-env APP_ENV=staging EXPO_NO_DOTENV=1 eas build --profile staging --platform android ",
25+
"build:staging:ios:local": "cross-env APP_ENV=staging sh -c './scripts/set-env.sh EXPO_NO_DOTENV=1 eas build --profile staging --platform ios --local'",
26+
"build:staging:android:local": "cross-env APP_ENV=staging sh -c './scripts/set-env.sh EXPO_NO_DOTENV=1 eas build --profile staging --platform android --local'",
2527
"build:production:ios": "cross-env APP_ENV=production EXPO_NO_DOTENV=1 eas build --profile production --platform ios",
2628
"build:production:android": "cross-env APP_ENV=production EXPO_NO_DOTENV=1 eas build --profile production --platform android ",
2729
"postinstall": "husky install",
@@ -37,7 +39,7 @@
3739
"e2e-test": "maestro test .maestro/ -e APP_ID=com.obytes.development"
3840
},
3941
"dependencies": {
40-
"@expo/metro-runtime": "^3.2.1",
42+
"@expo/metro-runtime": "^3.2.3",
4143
"@gorhom/bottom-sheet": "^4.6.3",
4244
"@hookform/resolvers": "^2.9.11",
4345
"@react-navigation/bottom-tabs": "^6.5.20",
@@ -47,18 +49,19 @@
4749
"@tanstack/react-query": "^5.37.1",
4850
"app-icon-badge": "^0.0.15",
4951
"axios": "^1.7.1",
50-
"expo": "~51.0.24",
52+
"expo": "~51.0.28",
5153
"expo-build-properties": "~0.12.4",
5254
"expo-constants": "~16.0.2",
53-
"expo-dev-client": "~4.0.21",
55+
"expo-dev-client": "~4.0.23",
5456
"expo-font": "~12.0.9",
5557
"expo-image": "~1.12.13",
5658
"expo-linking": "~6.3.1",
5759
"expo-localization": "~15.0.3",
58-
"expo-router": "~3.5.20",
60+
"expo-router": "~3.5.23",
5961
"expo-splash-screen": "0.27.5",
6062
"expo-status-bar": "~1.12.1",
6163
"expo-system-ui": "~3.0.7",
64+
"expo-updates": "~0.25.21",
6265
"i18next": "^22.5.1",
6366
"lodash.memoize": "^4.1.2",
6467
"moti": "^0.28.1",
@@ -68,7 +71,7 @@
6871
"react-error-boundary": "^3.1.4",
6972
"react-hook-form": "^7.51.4",
7073
"react-i18next": "^12.3.1",
71-
"react-native": "0.74.3",
74+
"react-native": "0.74.5",
7275
"react-native-avoid-softinput": "^4.0.2",
7376
"react-native-flash-message": "^0.4.2",
7477
"react-native-gesture-handler": "~2.16.2",

0 commit comments

Comments
 (0)