Use GitHub in xcode
Step 1: Add authentication for your Mac so that it can connect to GitHub.
Refer to the http://help.github.com/mac-set-up-git/ step by step operation can ================================================== ====================================== Step 2: to create a new project, add a repository in GitHub, connect to it through the new repository connection on the http://github.com/homepage, enter the relevant project information, and create a repository. After the project is created, the initial project page is displayed. The page is paused and used again in step 3. Create a project using xcode on Mac and use git for the project. During the creation process, use create local git repository for this project and specify the directory to store. ========================================================== ============================ Step 3: initialize and submit the project and return to the page after GitHub creates the project. There are several initialization methods. Here we choose to submit code from an existing warehouse. Run the following code.
Existing git Repo?
cd existing_git_repo
git remote add origin git@github.com:your_account/your_project.git
git push -u origin master
The above code connects the local repository to the remote repository and submits the code to the master branch.
====================================================================
Step 4: Submit code
For the newly created file, xcode will prompt a tag a, indicating that it is added.
For the edited file, xcode will prompt a m tag, indicating that it is modified.
Right-click the file to be updated and choose --> source control --> commit selected files to submit the changes to the local repository.
Select the file to be updated, and choose File> source control> push to store local changes to the remote server.
from:http://qiufangzhou.blog.163.com/blog/static/506421802011924102515390/