First remote version of Git source repository on Xcode

2620 단어 GitXcoderepository

Leading


Sometimes we need to manage the code by using Git. In our company we store the Git source repository on the server.
It's my business to manage that source. But when I try to create a new one by Xcode, I get problems.

Xcode can only create loal copy


Xcode can just create a local repository, and download the existing source from server.

After creating...

So we must find another way to create the one on server.

Create *.git on server


First of all, upload the original source to server.

Go into the project folder and create the hidden folder .git.

Then type below commands in project folder for preparing the first version.git add .
git commit -m "initial version"
At last go to the father folder of project folder and create the *.git folder.

You will find the *.git folder. And that is what we need!

Check out the Git source repository from server


This time go to Source Control -> Check Out..., and input the link where the Git source repository is.

The link format isssh://username@servername/absolute_directory_of_git_source_repository

Further more


You can go to setting up a repository to know more about set up a repository.

좋은 웹페이지 즐겨찾기