Open files in your host's file manager from inside Distrobox containers!
Overview • Features • Usage • Requirements • Installation • Contributing
A lightweight VS Code extension designed for developers working inside Distrobox containers. It restores the missing "Reveal in File Explorer" functionality, allowing you to open files and folders in your host OS's file manager seamlessly.
✨ Why use this extension? When using VS Code connected to a Distrobox container, the standard "Reveal in File Explorer" option is often missing or unavailable. This extension bridges that gap by using
distrobox-host-execto open files in your host's file manager (Nautilus, Dolphin, Thunar, etc.) with a single click.
| 🚀 Quick Access | 🔧 Flexible Integration |
|---|---|
| 🖱️ Context Menus - Right-click on files in Explorer sidebar or editor tabs | 📂 Any File Manager - Works with Nautilus, Dolphin, Thunar, and more |
| ⌨️ Command Palette - Access via "Reveal in Host Explorer" | 🐧 Native Feel - Seamless bridge between container and host |
| 📁 Files & Folders - Works with both files and directories | ⚡ Zero Config - Uses standard distrobox-host-exec |
- ✅ Zero Configuration - Works out-of-the-box with standard Distrobox setups
- 🎨 Seamless Integration - Appears in native VS Code context menus
- 🐧 Linux Native - Built specifically for the Linux + Distrobox workflow
- ⚡ Lightweight - Minimal performance impact on your editor
The extension provides the command: "Reveal in Host Explorer"
| Method | How to Use |
|---|---|
| 📁 Explorer Context Menu | Right-click any file or folder in the VS Code sidebar |
| 📑 Editor Tab Context Menu | Right-click the tab of any open file |
| ⌨️ Command Palette | Press Ctrl+Shift+P and type "Reveal in Host Explorer" |
🔧 How it works under the hood
When triggered, the extension executes the following command in your container:
distrobox-host-exec xdg-open "/absolute/path/to/directory"- If a file is selected → opens the parent directory
- If a directory is selected → opens that directory directly
To use this extension effectively, your environment must meet these criteria:
| Requirement | Description |
|---|---|
| 🐧 Distrobox | You are running VS Code inside a Distrobox container |
| 🔧 distrobox-host-exec | Pre-installed in standard Distrobox containers (must be in $PATH) |
| 🖥️ Host Environment | Linux host with xdg-open configured (GNOME, KDE, XFCE, etc.) |
⚠️ Note: This extension assumes 1:1 path mapping between host and container (the default Distrobox behavior with home directory mounting). Custom internal paths that don't exist on the host won't work.
To ensure VS Code connects to the Distrobox with your host user, you need to configure the remoteUser setting:
- Open the Command Palette (
Ctrl+Shift+P) - Search for "Dev Containers: Open Container Configuration File"
- Add the following line to the configuration:
"remoteUser": "${localEnv:USER}"Without this setting, VS Code may connect as root, which prevents xdg-open from accessing your host's desktop session (D-Bus, display server) and the file manager won't open.
- Open VS Code inside your Distrobox
- Go to Extensions view (
Ctrl+Shift+X) - Search for "Distrobox Reveal"
- Click Install
Install the .vsix file directly if building from source.
Want to contribute? We'd love your help!
-
Clone the repository
-
Install dependencies
-
Start development
- Press
F5or go to Run → Start Debugging - A new VS Code window will open with the extension loaded
- Press
-
Build the extension
npm run compile
Made with ❤️ for the Linux community
⭐ Star us on GitHub • 🐛 Report a Bug • 💡 Request a Feature