-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Integrates AppDevAnnouncements pod (#264)
* Integrates appdev-announcements pod * Fixes naming in Secrets.swift * Adds firebase logging for presenting announcement
- Loading branch information
1 parent
e261c3c
commit 43952cb
Showing
9 changed files
with
97 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
// | ||
// Keys.swift | ||
// Eatery | ||
// | ||
// Created by Kevin Chan on 2/22/20. | ||
// Copyright © 2020 CUAppDev. All rights reserved. | ||
// | ||
|
||
import Foundation | ||
|
||
struct Secrets { | ||
|
||
static let announcementsCommonPath = Secrets.secretDict["announcements-common-path"] as! String | ||
static let announcementsHost = Secrets.secretDict["announcements-host"] as! String | ||
static let announcementsPath = Secrets.secretDict["announcements-path"] as! String | ||
static let announcementsScheme = Secrets.secretDict["announcements-scheme"] as! String | ||
|
||
private static let secretDict: NSDictionary = { | ||
guard let path = Bundle.main.path(forResource: "Secrets", ofType: "plist"), | ||
let dict = NSDictionary(contentsOfFile: path) else { return [:] } | ||
return dict | ||
}() | ||
|
||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -14,12 +14,31 @@ We use [CocoaPods](http://cocoapods.org) for our dependency manager. This should | |
To access the project, clone the project, and run `pod install` in the project directory. | ||
|
||
### 2. Configuration | ||
We use [Firebase](https://firebase.google.com) for our user analytics. You will have to retrieve a `GoogleService-Info.plist` from Firebase and then place it inside the `Eatery/` directory. | ||
1. We use [Firebase](https://firebase.google.com) for our user analytics. You will have to retrieve a `GoogleService-Info.plist` from Firebase and then place it inside the `Eatery/` directory. | ||
|
||
We also use `GraphQL` to retrieve data from our backend server and use `Apollo` on the client side in order to help us do so. | ||
2. We also use `GraphQL` to retrieve data from our backend server and use `Apollo` on the client side in order to help us do so. | ||
|
||
To setup `Apollo`, you will have to first install it by running `npm install -g [email protected]` in the project directory (make sure you specify version 1.9). | ||
|
||
You will also have to retrieve a `schema.json` file by running: `apollo schema:download --endpoint={Backend_URL} schema.json` in the <strong>project directory</strong>. | ||
|
||
3. Lastly, you will need a `Secrets.plist` file that you will want to place inside the `Eatery/Supporting/` directory. The following is a template for the `Secrets.plist` file: | ||
|
||
``` | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | ||
<plist version="1.0"> | ||
<dict> | ||
<key>announcements-scheme</key> | ||
<string>insert-value-here</string> | ||
<key>announcements-host</key> | ||
<string>insert-value-here</string> | ||
<key>announcements-common-path</key> | ||
<string>insert-value-here</string> | ||
<key>announcements-path</key> | ||
<string>insert-value-here</string> | ||
</dict> | ||
</plist> | ||
``` | ||
|
||
Finally, open `Eatery.xcworkspace` and enjoy Eatery! |