r/vscode • u/Turbulent-Metal-6287 • 10h ago
Shared Remote History
If you work with Linux servers or regularly connect to VMs using VS Code Remote SSH, especially when multiple people use the same Linux user, you might find this extension useful.
Why? Here's the problem I ran into.
VS Code keeps a Local History of your file changes, which is great when you need to roll something back.
But there's a catch.
Let's say two people are working on the same VM using the same `root` user. One connects using the server's IP address, and the other uses an SSH host alias.
Both are editing the exact same file, but their changes don't show up in each other's Timeline history.
Now imagine something breaks in production, and you need to roll back a change quickly. The history exists on the server, but you can't see it in your Timeline.
So now you have to call the guy who made the change, probably wake him up, just to get an older version of the file.
So I started digging.
After looking into how VS Code stores Local History, I found out that it treats different SSH connection names as separate sources, even when they all point to the exact same server.
For example:
- Someone connects using `10.6.115.14`
- Someone else connects using `server14`
Same VM, same user, same file, but separate history entries.
So how did I fix it?
Instead of asking everyone to change their SSH configurations, I thought, why not just build an extension that collects all those history entries an shows them in one place?
And that's how **Shared Remote History** came to life.
It's a VS Code extension that:
✅ Combines Local History from different SSH aliases.
✅ Shows those changes directly in VS Code's original Timeline panel.
✅ Lets you view and compare older versions of your files.
✅ Doesn't require changing anyone's SSH configuration or modifying the original history files.
And since I figured someone else might be dealing with the same headache, I decided to make it public.**
The extension is now available for free on the **Visual Studio Marketplace**, and I've also made the source code available on GitHub.
If you're working in a shared Linux/VM environment, give it a try. Hopefully it'll save you from waking someone up at 3 AM just to roll back a file.
🔗 **VS Code Marketplace:**
https://marketplace.visualstudio.com/items?itemName=aliadnan-dev.shared-remote-history
💻 **GitHub:**
https://github.com/NetProbeSupport/shared-remote-history
Feedback, suggestions, and contributions are welcome!

