Notice: This is not a duplicate of this, so also no duplicate of this. Also not duplicate of this
Abstract:
I'd like to edit two files within the same branch(?) (both open in same IDE; both compiling to the same executable), while being able to commit/push/pull them on individual branches.
Concrete Example
Scenario steps:
- I'm creating a
Computercomponent in filecomputer.file. I manage it in branchcomponent/computer. - I figure out, I will need to implement a
Mousecomponent in filemouse.file. I also manage it in branchcomponent/computer - I will be working on
ComputerandMousesimultaneously (adjustingMouseto whatComputerneeds). - I'm doing regular local commits to save my progress.
- While I'm still working on both components, other team members like to also use the
Mousecomponent in it's current version. - The
Mousecomponent should best be shared in the main branch (developbranch). But as theComputer componentis long before finished,developbranch should not know about it.
Problem:
Computer.file and Mouse.file are worked on within the same branch (component/computer), so merging that with develop, will also add Computer.file into develop (which is unwanted)
What I want:
I'd like to be able push/merge only Mouse.file into develop (regularly).
My idea of the solution is to have Computer.file on branch component/computer and Mouse.file on branch component/mouse, while being able to edit both branches in one IDE and branch and being able to commit/push/merge both branches independently.