Visual Studio 2019 Github extension commands: "pop and restore staged" vs "pop all as unstaged"?

Viewed 4962

What is the difference between the following commands in Visual Studio 2019 for GIT stash? pop and restore staged (--index) pop All as unstaged

while using https://visualstudio.github.com/

1 Answers

Found a good article : https://www.thomasclaudiushuber.com/2019/04/10/the-git-stash-functionality-in-visual-studio-2019 - and here is the answer:

  • Pop/Apply and Restore Staged – this will pop/apply the changes to your branch and it will also ensure that files that you had staged before are staged again
  • Pop/Apply All as Unstaged – this will pop/apply the changes to your branch and it won’t stage the files that you had staged before.

If you hadn’t any staged files before you created the stash, then you won’t see a difference between the two options.

Related