Integrate Projects in a single project
I have same xcode project on two deferent macbooks with different code.we need to merge that code but we are not using any git account.We need to merge same file as well,I mean we have same viewcontroller and added two people add a code in single view controller How i can merge it.
I have a view controller Name “XYZ”and Person 1 added “Login Method”
into “XYZ” and person 2 added “Sign up Method” into XYZ. and both code
are on deferent macbook without any git account how I can
Why can't I git subtree pull --rebase? Why isn't the git stash unique per branch? Repository not found in git jenkins GIT: How do I rebase nested branches? Grit's clone method is undefined? Updating a git mirror of an SVN repository
2 Solutions collect form web for “Integrate Projects in a single project”
Since you use the git tag, I will provide the way to do version control by git.
First, please sign up account for bitbucket (free for private repository) or github (only free for public repository). And create a repository. They are as the remote git repository(repo).
Then use git bash for local repository.
In one macbook, use these steps:
git clone <URL for your bitbucket or github repo>
- copy your xcode project in reponame folder
git add .
git commit -am 'code version from first macbook'
Now the code in the first macbook is pushed in your remote repo.
In the other macbook, use these steps:
- In an empty folder, use
- copy your xcode project in this folder
git add .
git commit -am 'code version from second macbook'
git remote add origin <URL for your bitbucket or github repo>
git pull origin master
- Now the code from macbook1 is merging in macbook2
- If there has conflict files, you should check and save them, and then use
git add .and
git commit -m 'solve merge conflict'.
- Now this is the version that you merge the different macbooks together. You can push the version in remote repo by
More git related, you can refer git book.
Any version control system comes to handy in this kind of situations. Merging manually is the option available other than version control system. Either merge using version control system like git or manually merge the files which is very hard to workout.