A Visual Studio extension that copies open editor tab file paths to the clipboard — ready to paste directly into GitHub Copilot Chat or any AI prompt.
Why?
When working with GitHub Copilot Chat, you often want to reference specific files with #file: tags. Doing this manually is tedious. This extension adds a single menu action (or keyboard shortcut) to grab all the paths you need in one click.
Features
- Copy selected tabs — Interactive dialog to pick exactly which tabs to include
- Copy all tabs — All open documents in one go, no dialog
- Copy pinned tabs — Only pinned tabs (great for "context files" workflows)
- Copy active tab — Just the file you're currently editing
- Append active tab — Adds the current file's path to whatever is already on the clipboard (build up your list incrementally)
- Paths are relative to the solution root — portable and clean for prompts
- Automatically skips Copilot baseline temp files (files starting with
~)
Commands
All commands are available under Edit → Copy Tab Paths in the menu bar.
| Command | Description |
|---|---|
| Copy Tab Paths… | Opens a dialog to select individual tabs to copy |
| Copy All Tab Paths | Copies paths of all open tabs immediately |
| Copy Pinned Tab Paths | Copies only the paths of pinned tabs |
| Copy Active Tab Path | Copies the path of the currently active document |
| Append Active Tab Path | Appends the active document's path to the clipboard |
Usage Example
- Open the files you want to reference in Visual Studio.
- Pin the "context files" you always want included (optional).
- Click Edit → Copy Tab Paths → Copy All Tab Paths.
- Switch to GitHub Copilot Chat and paste — you get something like:
src/Services/OrderService.cs
src/Models/Order.cs
src/Controllers/OrderController.cs
- Prepend
#file:to each line and you have a ready-to-use Copilot context block.
Requirements
- Visual Studio 2022 (17.0) or later — Community, Professional, or Enterprise