Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to create dev/staging/production environments

Tags:

ios

swift

I'm trying to create an Xcode project that works in a development environment (using the computer as a local host), staging environment (a specific endpoint on a server), and a production environment (another specific server endpoint). I have found a few different tutorials about how to set this up. Some solutions suggest creating different target, some suggest creating different configurations. What is the most effective way to do this?

like image 640
Tometoyou Avatar asked Aug 15 '26 19:08

Tometoyou


1 Answers

Following are the steps to create different schemes

  1. Select the target
  2. Create new scheme and give specific name to scheme (Dev,Staging,Prod,Debug)

i have attached screen shot for your reference

Sample Screen Shot for reference

enter image description here

if you want to set different url for different schemes then do the following steps:

1.Go to Build Setting

2.Go to user defined section

3.Create macros and specify urls for each environment

like image 74
Sachin Amrale Avatar answered Aug 18 '26 09:08

Sachin Amrale