Is it possible to use git stash command from Visual Studio

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/54071448/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-19 13:15:44  来源:igfitidea点击:

Is it possible to use git stash command from Visual Studio

gitvisual-studiogit-stash

提问by Shahar Shokrani

I'm using Visual Studio 2017's Team Explorer to work with a gitrepository.

I'm using Visual Studio 2017's Team Explorer to work with a gitrepository.

Every time I'm uses the git stashor git stash pop, I need to open the Git Bash console and navigate to my project folder and run the commands.

Every time I'm uses the git stashor git stash pop, I need to open the Git Bash console and navigate to my project folder and run the commands.

Is there any way to stash within Visual Studio (2017)?

Is there any way to stash within Visual Studio (2017)?

回答by Hans Ke?ing

In VS2019(not in VS2017 or before) in the Team Explorer window, you can select "Changes". Right next to the "Commit" button, there is a "Stash"...

In VS2019(not in VS2017 or before) in the Team Explorer window, you can select "Changes". Right next to the "Commit" button, there is a "Stash"...

回答by ikkentim

In Visual Studio 2017 this feature is not available by default, but there's an extension for this:

In Visual Studio 2017 this feature is not available by default, but there's an extension for this:

https://marketplace.visualstudio.com/items?itemName=vii.GitStashExtension

https://marketplace.visualstudio.com/items?itemName=vii.GitStashExtension