0

I have created a remote branch B from another branch A.

git branch B
git checkout B

and did some changes in B and checked git status.

Now when I checkout A and same changes are reflecting in A git status.

git checkout A
git status

might sound very silly but Why?...I am new to git

ts178
  • 321
  • 1
  • 6
  • 20
  • You haven't staged (git add) or committed (git commit) anything to your B branch. – j08691 Sep 19 '18 at 15:34
  • I did "git add -A" in branch B...but still same status for both branch – ts178 Sep 19 '18 at 15:44
  • but you didn't do `git commit` after `git add`, did you? – umläute Sep 19 '18 at 16:00
  • Possible duplicate of [Modified files in a git branch are spilling over into another branch](https://stackoverflow.com/questions/246275/modified-files-in-a-git-branch-are-spilling-over-into-another-branch) – phd Sep 19 '18 at 16:16
  • https://stackoverflow.com/a/246298/7976758 – phd Sep 19 '18 at 16:16

0 Answers0