Skip to content
| Marketplace
Sign in
Visual Studio Code>Other>Copy Block PathNew to Visual Studio Code? Get it now.
Copy Block Path

Copy Block Path

pengkangzhen

| (0) | Free
Copy relative path with line range to clipboard, e.g. @response_letter.tex:46-47
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

Copy Block Path

Copy the current file's relative path with line number(s) to clipboard.

Output format

Situation Output
Cursor on line 46 @response_letter.tex:46
Select lines 46–47 @response_letter.tex:46-47

Usage

  1. Place cursor or select lines in editor
  2. Right-click → Copy Block Path (@file:line), or use the shortcut

Keybinding

OS Shortcut
macOS ⌘⇧⌥C
Windows/Linux Ctrl+Shift+Alt+C

Install from VSIX

code --install-extension copy-block-path-0.1.0.vsix
  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2026 Microsoft