Created
September 23, 2017 18:51
-
-
Save YuriNachos/185c6ad54c7848d4381ebf11b75cb80e to your computer and use it in GitHub Desktop.
Env
This file contains hidden or 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
| enum Environment { | |
| case development | |
| case staging | |
| case production | |
| } | |
| let environment: Environment = .development | |
| switch environment { | |
| case .development: | |
| // set web service URL to development | |
| // set API keys to development | |
| print("It's for development") | |
| case .staging: | |
| // set web service URL to staging | |
| // set API keys to development | |
| print("It's for staging") | |
| case .production: | |
| // set web service URL to production | |
| // set API keys to production | |
| print("It's for production") | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment