If I want to clone/fork/work off of project A on a new project, B, what would be the best approach?
My current idea is to do this:
- Clone repository A, and create two remotes. The first, a meaningful name pointing to the repository URL of repository A, and the second,
origin
, which points to repository B.
The reason I want to do this is so that repository B can have repository A as a base, and any time changes are made to repository A that I want to merge in, I can just git pull <repository-A-remote-name> <branch>
and when I want to push to repository B I just push to origin.
Has anyone ever had this sort of workflow before, and if so would you say that this is a good approach, or have you tried something else?
Note: pull requests on GitHub are not necessary here because project A never needs the changes of project B, but project B will always need to merge in updates to project A.