{"id":23927100,"url":"https://github.com/rolemodel/rmshostselector","last_synced_at":"2025-02-24T01:14:20.570Z","repository":{"id":62452093,"uuid":"13632505","full_name":"RoleModel/RMSHostSelector","owner":"RoleModel","description":"Manages server selection for iOS apps","archived":false,"fork":false,"pushed_at":"2014-06-04T03:31:12.000Z","size":430,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":25,"default_branch":"master","last_synced_at":"2025-02-06T00:35:08.645Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Objective-C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/RoleModel.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2013-10-16T22:02:41.000Z","updated_at":"2014-06-04T03:31:11.000Z","dependencies_parsed_at":"2022-11-01T23:45:44.130Z","dependency_job_id":null,"html_url":"https://github.com/RoleModel/RMSHostSelector","commit_stats":null,"previous_names":[],"tags_count":8,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RoleModel%2FRMSHostSelector","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RoleModel%2FRMSHostSelector/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RoleModel%2FRMSHostSelector/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RoleModel%2FRMSHostSelector/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/RoleModel","download_url":"https://codeload.github.com/RoleModel/RMSHostSelector/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240400335,"owners_count":19795332,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-01-05T22:14:14.746Z","updated_at":"2025-02-24T01:14:20.536Z","avatar_url":"https://github.com/RoleModel.png","language":"Objective-C","funding_links":[],"categories":[],"sub_categories":[],"readme":"RMSHostSelector \n===============\n\nManages server selection for iOS apps\n\nUse `RMSHostSelector` to allow user-selection of a server host when\ntesting/debugging iOS apps. Host choices are defined in a Hosts.plist\nfile that you add to your app's resources. Each host is defined as a\nkey/value pair (i.e. production =\u003e myserver.com)\n\nRelease builds should not permit user-selection of a back-end server.\nFor these builds, preference is given to the `production` key in the\nHosts.plist file. All other keys will be stripped out of the bundled\nHosts.plist file and the user will not be prompted for server selection.\nThe special handling is performed by the `host_selector_build_phase.sh`\nthat must be added as a \"Run Script\" build phase in order to take\neffect.\n\nA key other than `production` can be coerced by defining the\n`RMS_HOST_KEY` preprocessor macro. The value specified by this key must\nbe quoted and must match one of the keys in the Hosts.plist file.\n\nNon-release builds can also make use of the `RMS_HOST_KEY` override. For\nnon-release builds where `RMS_HOST_KEY` is defined, the Hosts.plist file\nis left in tact, but user-selection of the host is circumvented.\n\nCustom Build Phase\n------------------\n\nOnce you've installed this CocoaPod, you'll need to set up a custom\nbuild phase to incorporate `host_selector_build_phase.sh` into your\nproject. Do this by navigating to the application target in Xcode\nand selecting *Add Build Phase -\u003e Add Run Script Build Phase* from the \n*Editor* menu. \n\n![Add run script build phase](https://raw.github.com/RoleModel/RMSHostSelector/854ea9b2ecfa04935a71a5df16fee708bc8481cd/Screenshots/Add%20Run%20Script.png?login=tingraldi\u0026token=e6be81f186e32e5d8ac5f4c45f844632)\n\nThen, in the shell script entry area for the newly\nadded run build phase enter the following:\n\n`\"${SRCROOT}\"/Pods/RMSHostSelector/Resources/host_selector_build_phase.sh`\n\nThat's all you need to do to get the default behavior, provided that\nyour `Hosts.plist` file contains an entry for the `production` host.\n\n\n\n![Run script configuration](https://raw.github.com/RoleModel/RMSHostSelector/854ea9b2ecfa04935a71a5df16fee708bc8481cd/Screenshots/Run%20Script%20Configuration.png?login=tingraldi\u0026token=efa9853fa21ee863751fb6fec121cfed)\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frolemodel%2Frmshostselector","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frolemodel%2Frmshostselector","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frolemodel%2Frmshostselector/lists"}