This situation I have is the following. I have an old project in aa Solution I will call Old Project A
and Old Solution A
. It was a divergent branch (just a copy of the SVN for development) from the main Project and Solution. This was in SVN Tortoise. I have a copy of this Old Project A
and Old Solution A
on my computer.
Then we put the main line of our solution and project into Git. Much development has taken place and there are many commits in Git.
So I now have The Git Project A
within Git Solution A
.
I want to introduce The Old Project A
into a branch of the Git repository.
What I have done is created 2 new branches I will call NewBranch A
and NewBranch B
, both from the master branch.
From NewBranch B
I deleted the Git Project A
and replaced it with Old Project A
, committed all the modified files but did not commit all the deleted files (which had been added in the newer Git Project A
).
git checkout NewBranch B
git merge NewBranch A
But this just keeps the Old Project A
code and does not merge the Git Project B
. I was of course expecting merge conflicts. I wanted them to sort them out manually. But all I got was the Old Project A
code.
How can I merge the Old Project A
code with the Git Project B
and then manually sort the conflicts ?
I can see 2 options for your situation.
But if you insist on using git,
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.