Skip to content

psh4607/copy-path-with-line

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 

Repository files navigation

Copy Path With Line

VS Code extension that copies the relative file path with line number(s) to clipboard.

Format

  • Single line: @src/app/page.tsx#7
  • Multiple lines: @src/app/page.tsx#5-10

Usage

  1. Place cursor on a line or select multiple lines
  2. Press Cmd+I (macOS)
  3. Path is copied to clipboard, status bar shows confirmation

Keybinding

Add to your keybindings.json:

{
  "key": "cmd+i",
  "command": "copyPathWithLine.copy",
  "when": "editorTextFocus"
}

Install

Symlink to VS Code extensions directory:

ln -sf /path/to/copy-path-with-line ~/.vscode/extensions/copy-path-with-line

Then restart VS Code.

License

MIT

About

VS Code extension - Copy relative file path with line number(s) to clipboard

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors