Skip to content
| Marketplace
Sign in
Visual Studio Code>Other>Copy File LocationNew to Visual Studio Code? Get it now.
Copy File Location

Copy File Location

moonjong93

| (0) | Free
Copy file path with line numbers in simple or markdown format
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

Copy File Location

Copy selected code's file path and line numbers to clipboard.

Features

Two formats supported:

Command Output Example
Simple src/api/folders.ts:10-15
Markdown [folders.ts:10-15](https://github.com/moonjong93/copy-file-location/blob/HEAD/src/api/folders.ts#L10-L15)

Keyboard Shortcuts

Shortcut Format
Cmd+Shift+L (Mac) / Ctrl+Shift+L (Windows) Simple
Cmd+Shift+Alt+L (Mac) / Ctrl+Shift+Alt+L (Windows) Markdown

Usage

  1. Select lines in the editor
  2. Press the shortcut
  3. Done! Path copied to clipboard

License

MIT

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2025 Microsoft