I am working (one) on a project that needs to add several functions. I use to create a branch for each function. After the function has been developed and well tested, I combine this branch with the main branch.
Now I run the function (let it enable function A) on branch-A, which is not finished yet. However, I urgently need to create a new function B and press it before the completion of function A. That's why I created branch-Band switched to it.
However, by running the command git status, I can see all the changes that I made in branch-A. I do not understand this default behavior. I expected to see “no change” because they are different industries. I absolutely need the commit in branch B to ignore everything I do in branch A.
What am I missing? How to create the right workflow?
source
share