I have two directories, A & B, which differ very little in their content. A is already init’d into a git repo and has a number of local commits to its master branch. Directory B is not under SCM and it’s basically just the result of manually copying all the files over from A (sans the .git directory), editing some of them, and adding some new ones. Now I want to make the contents of B a branch of the repo in A and, if possible, still host development of the new branch in directory B… but I have no idea how to accomplish that as I am a total git n00b, and don’t quite yet understand its approach to SCM enough to find the answer on my own in the documentation. Any tips/pointers? Thanks in advance!
Share
copy A/.git into B/.git. Then do what you normally would do for the branching.
You can then sync changes like this:
or the other way around.