Xcode default is by source control work Git,android Studio built-in also has, previously written two articles about window hosting Android code to GitHub, always wanted to write a piece about the managed code on Mac to the article, today finally have time to write, The default with Git in Xcode is really nice, and for people who are accustomed to git, it's very comfortable to open Xcode in the third option to move out of an existing project, so if you need to modify the code on GitHub or if the company is co-developing, you can choose this option:
Hosting to GitHub
There are two ways to host it, one is to use GIT commands to host the code to GitHub, and there's a handy way to use GitHub's visualizer address, https://mac.github.com/, to download the client, You need to go to GitHub to register an account, followed by the use of tools;
1. Initial page, note plus add warehousing:
2. Select the location of the local warehousing:
3. Create warehousing, pay attention to Commit&sync, if any, you can click the rotation icon on the left:
4. Submit Your Code
The submitted code can be seen in the 5.GitHub personal storage repository
6. Warehouse Detail View
7. Local tools management can see the code and time to submit, other places themselves can be a little bit to see, very fast client tools;
GitHub move out
1. First open the default initial page for Xcode:
2. Move out of GitHub managed code
3. Modify the storage location, relatively simple is not;
4. Modify the code in VIEWCONTROLLER.M to the code in Viewdiaload:
-(void) viewdidload { [super viewdidload]; Additional setup after loading the view, typically from a nib. NSLog (@ "flyelephant");}
5. Right-click on the file ViewController.h commit code:
6. Write the log, submit to the code to the local, because I did not set up, so can not be submitted to GitHub, interested in their own research;
The line pen hurriedly, unavoidably omission, if have improper, many correct, this article address: http://www.cnblogs.com/xiaofeixiang/
iOS development-xcode code hosting to GitHub