Skip to content

Commit 9266758

Browse files
authored
Add steps to configure different environments for the test app. (#10491)
1 parent b8c85f7 commit 9266758

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

FirebaseSessions/README.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,20 @@ Follow the [Main Firebase Readme](https://github.com/firebase/firebase-ios-sdk#d
99
- `generate_project.sh` uses [cocoapods-generate](https://github.com/square/cocoapods-generate) to create an Xcode Workspace that has the SDK installed for all the SDK's supported platforms. This is useful for test-based development.
1010
- `generate_testapp.sh` generates and opens a test app with the Sessions SDK included. This is useful for developing the Sessions SDK against a real app.
1111

12+
### Switching dev environments - Autopush/Staging/Prod
13+
14+
SDK is configured to send events to different environments. To enforce different environments for sending events, we use an environment variable to configure the specific environment. Since environment variables are enforced in the context of the App, use the TestApp to send events to different environments after using the following configuration steps.
15+
16+
- Enter "Edit scheme" - On the title bar menu "Product" > "Scheme" > "Edit Scheme"
17+
- Ensure "Run" is selected on the left tab
18+
- On the right hand side, choose the "Arguments" tab
19+
- Under the "Environment Variables", add the following variable to configure the environment
20+
- For "AUTOPUSH" - "FirebaseSessionsRunEnvironment" -> "AUTOPUSH"/"autopush"
21+
- For "STAGING" - "FirebaseSessionsRunEnvironment" -> "STAGING"/"staging"
22+
- For "PROD" - "FirebaseSessionsRunEnvironment" -> "PROD"/"prod"
23+
24+
NOTE: Default is PROD. Not configuring any flags would mean the events are sent to PROD environment.
25+
1226
### Debugging
1327

1428
### Command Line Arguments

0 commit comments

Comments
 (0)