{"id":13476619,"url":"https://github.com/mattt/GroundControl","last_synced_at":"2025-03-27T03:30:35.349Z","repository":{"id":4495720,"uuid":"5635061","full_name":"mattt/GroundControl","owner":"mattt","description":"Remote configuration for iOS","archived":true,"fork":false,"pushed_at":"2021-06-24T11:45:46.000Z","size":54,"stargazers_count":1941,"open_issues_count":4,"forks_count":124,"subscribers_count":91,"default_branch":"master","last_synced_at":"2025-03-19T13:02:52.513Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Objective-C","has_issues":false,"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/mattt.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":"2012-08-31T23:13:59.000Z","updated_at":"2025-03-02T23:22:39.000Z","dependencies_parsed_at":"2022-07-31T03:48:52.220Z","dependency_job_id":null,"html_url":"https://github.com/mattt/GroundControl","commit_stats":null,"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mattt%2FGroundControl","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mattt%2FGroundControl/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mattt%2FGroundControl/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mattt%2FGroundControl/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mattt","download_url":"https://codeload.github.com/mattt/GroundControl/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245778276,"owners_count":20670682,"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":"2024-07-31T16:01:32.641Z","updated_at":"2025-03-27T03:30:34.838Z","avatar_url":"https://github.com/mattt.png","language":"Objective-C","funding_links":[],"categories":["Objective-C","Utility"],"sub_categories":[],"readme":"# GroundControl\n**Remote configuration for iOS**\n\n\u003e **Note**: This project is no longer being maintained.\n\nMany developers don't realize that they are allowed to remotely control the behavior of their app (provided that the application isn't downloading any new code).\n\nGroundControl gives you a dead-simple way to remotely configure your app, allowing you to add things like [feature flags](http://code.flickr.com/blog/2009/12/02/flipping-out/), impromptu [A/B tests](http://en.wikipedia.org/wiki/A/B_testing), or a simple [\"message of the day\"](http://en.wikipedia.org/wiki/Motd_%28Unix%29).\n\nIt's built on top of [AFNetworking](https://github.com/afnetworking/afnetworking), and provides a single category on `NSUserDefaults` (just add `#import \"NSUserDefaults+GroundControl.h\"` to the top of any file you want to use it in).\n\n## Client Code\n\n```objective-c\nNSURL *URL = [NSURL URLWithString:@\"http://example.com/defaults.plist\"];\n[[NSUserDefaults standardUserDefaults] registerDefaultsWithURL:URL];\n```\n\n...or if you need callbacks for success/failure, and prefer not to listen for a `NSUserDefaultsDidChangeNotification`:\n\n```objective-c\nNSURL *URL = [NSURL URLWithString:@\"http://example.com/defaults.plist\"];\n[[NSUserDefaults standardUserDefaults] registerDefaultsWithURL:URL\n  success:^(NSDictionary *) {\n    // ...\n} failure:^(NSError *) {\n    // ...\n}];\n```\n\n...or if you need to use an HTTP method other than GET, or need to set any special headers, specify an `NSURLRequest`:\n\n```objective-c\nNSURL *URL = [NSURL URLWithString:@\"http://example.com/defaults.plist\"];\nNSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:URL];\n[[NSUserDefaults standardUserDefaults] registerDefaultsWithURLRequest:request\n  success:^(NSURLRequest *, NSHTTPURLResponse *, NSDictionary *) {\n    // ...\n} failure:^(NSURLRequest *, NSHTTPURLResponse *, NSError *) {\n    // ...\n}];\n```\n\n## Server Code\n\nGroundControl asynchronously downloads and reads a remote plist file. This could be a static file or generated dynamically, like in the following examples (see also the complete Sinatra application found in `example/server`):\n\n### Ruby\n\n```ruby\nrequire 'sinatra'\nrequire 'plist'\n\nget '/defaults.plist' do\n  content_type 'application/x-plist'\n\n  {\n    'Greeting' =\u003e \"Hello, World\",\n    'Price' =\u003e 4.20,\n    'FeatureXIsLaunched' =\u003e true\n  }.to_plist\nend\n```\n\n### Python\n\n```python\nfrom django.http import HttpResponse\nimport plistlib\n\ndef property_list(request):\n    plist = {\n         'Greeting': \"Hello, World\",\n         'Price': 4.20,\n         'FeatureXIsLaunched': True,\n         'Status': 1\n    }\n\n    return HttpResponse(plistlib.writePlistToString(plist))\n```\n\n### Node.js\n\n```javascript\nvar plist = require('plist'),\n    express = require('express')\n\nvar host = \"127.0.0.1\"\nvar port = 8080\n\nvar app = express()\n\napp.get(\"/\", function(request, response) {\n        response.send(plist.build(\n            {\n                'Greeting': \"Hello, World\",\n                'Price': 4.20,\n                'FeatureXIsLaunched': true,\n                'Status': 1\n            }\n        ).toString())\n})\n\napp.listen(port, host)\n```\n\n## License\n\nGroundControl is available under the MIT license. See the LICENSE file for more info.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmattt%2FGroundControl","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmattt%2FGroundControl","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmattt%2FGroundControl/lists"}