Skip to content
| Marketplace
Sign in
Visual Studio Code>Other>Local Copy ExtensionNew to Visual Studio Code? Get it now.
Local Copy Extension

Local Copy Extension

paulkelly

|
23 installs
| (0) | Free
Copies selected open files to clipboard with filenames
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

Local Copy Extension

Description

Local Copy Extension allows you to copy the contents of all open files in Visual Studio Code to the clipboard, including their absolute filenames. This can be useful for copying a code context to paste into a large language model like ChatGPT.

Purpose

I created this extension to save time when copying a group of files to paste into ChatGPT for my coding work. Manually copying each file's content was tedious, so this extension automates the process of copying a group of open files in Visual Studio Code.

Features

  • Copy the contents of all open files to the clipboard (shortcut: Ctrl+Shift+C)
  • Includes absolute filenames in the copied content

Usage

  1. Open multiple files in Visual Studio Code and make sure they are visible in the editor.
  2. Press Ctrl+Shift+C (default keybinding) to copy the contents of all open files to the clipboard.

Known Issues

  1. Only visible files in the editor are copied. If you have files open but not visible in the editor, their content will not be copied.

Example Output

If you have the following files open:

  1. /path/to/your/project/file1.txt:

    Hello, this is the content of the first file.
    
  2. /path/to/your/project/file2.js:

    console.log('This is the second file.');
    
  3. /path/to/your/project/file3.py:

    print("This is the third file.")
    

Pressing Ctrl+Shift+C will copy the following content to the clipboard:

----- /path/to/your/project/file1.txt -----

Hello, this is the content of the first file.

----- /path/to/your/project/file2.js -----

console.log('This is the second file.');

----- /path/to/your/project/file3.py -----

print("This is the third file.")
  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2025 Microsoft