DEV Community

harleybl
harleybl

Posted on

1 1

Diff GIT stash versus working directory in Visual Studio 2019

Have you previously stashed some code using git stash and want to see what applying it would do to your workspace?

I had this happen today and my first thought was to reach for "git stash show -p" on the command line. While this is a useful command for a small stash it is not that easy to see the changes in a pretty side by side manner.

The project I am working on is a C# project and I am already using Visual Studio 2019 for the project so I was wondering if there was a way that the tool could help me. Sure enough, the Visual Studio team has already thought of this.

To view a stash within Visual Studio, follow these steps:

  1. Open the Team Explorer
  2. Go to the Changes View within Team Explorer.
  3. Double click on the Stash in the stashes section (below Changes)

This will open up the stash details and allow you to see the files contained in the stash. To see the differences of a specific file in the stash, double click that file to see the difference between the stash and your workspace.

I found this useful, hopefully others will find it useful as well.

Image of Timescale

🚀 pgai Vectorizer: SQLAlchemy and LiteLLM Make Vector Search Simple

We built pgai Vectorizer to simplify embedding management for AI applications—without needing a separate database or complex infrastructure. Since launch, developers have created over 3,000 vectorizers on Timescale Cloud, with many more self-hosted.

Read more

Top comments (0)

Image of Docusign

🛠️ Bring your solution into Docusign. Reach over 1.6M customers.

Docusign is now extensible. Overcome challenges with disconnected products and inaccessible data by bringing your solutions into Docusign and publishing to 1.6M customers in the App Center.

Learn more