https://github.com/sentriz/add-osc-8-hyperlink
read from stdin, find relative or absolute paths, output osc-8 file:// hyperlinks to terminal
https://github.com/sentriz/add-osc-8-hyperlink
Last synced: 11 months ago
JSON representation
read from stdin, find relative or absolute paths, output osc-8 file:// hyperlinks to terminal
- Host: GitHub
- URL: https://github.com/sentriz/add-osc-8-hyperlink
- Owner: sentriz
- Created: 2022-11-01T20:11:07.000Z (over 3 years ago)
- Default Branch: master
- Last Pushed: 2022-11-04T16:41:27.000Z (over 3 years ago)
- Last Synced: 2025-03-30T14:46:16.677Z (about 1 year ago)
- Language: Go
- Size: 5.86 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
Awesome Lists containing this project
README
# add-osc-8-hyperlink
_read from stdin, find relative or absolute paths, output osc-8 `file://` hyperlinks to terminal_
[for terminal emulators that support osc-8](https://gist.github.com/egmontkob/eb114294efbcd5adb1944c9f3cb5feda)
#### installation
`go install go.senan.xyz/add-osc-8-hyperlink@latest`
#### example integrations
##### fish and git diff, status, log
```fish
function git
if isatty stdout; and contains -- $argv[1] diff status log
command git -c color.status=always -c color.ui=always $argv | add-osc-8-hyperlink
return
end
command git $argv
end
```
##### fish and ripgrep
```fish
function rg
if isatty stdout
command rg --color=always --line-number $argv | add-osc-8-hyperlink
return
end
command rg $argv
end
```
##### fish and git video