Last active
July 14, 2022 15:17
-
-
Save jspiewak/77f2fb3c321b396efe72 to your computer and use it in GitHub Desktop.
Configure iTerm2 to handle x-man-page URLs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- Create a new profile, e.g. Man Page Viewer | |
- Set the command to `bash -c "echo $$HOST$$ | sed -E 's/(.*)\/(.*)/\1 \2/' | xargs man"` | |
- Select x-man-page from the "Schemes handled" drop down |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The
bash -c
was necessaryHad to change from
$$HOST$$$$PATH$$
to just$$HOST$$
because iTerm2 was not substituting and only sending$$HOST
to theecho
.