I am new to version control and I have a question about branching. I have the following branches: "dev" and "master" Let's say I add or modify a file in dev, I run "git status" and it shows what I changed. Now, if I switch to the "master" branch, I also see pending changes when I run "git status". Should it be right? However, as soon as I run "git commit ...", I will receive commit messages related to the specific branch I went through.
I thought and hoped that each branch would be different. It seems like it is, but I see where I can get confused if I commit the wrong branch when I switch back and forth.
source
share