iterm2-dwim
iterm2-dwim copied to clipboard
Try relative path relative to root of git repository
Currently a parse rule exists that tries to interpret a relative path as relative to the current directory CWD
.
However, it's fairly common to be in an internal directory of the git repo, and yet be looking at a path in some output that is relative to the root of the git repo. In that situation, no parse rule will cerrently match.
We could add a parse rule that works as follows: ask git
whether CWD
is in a git repo and if so what the root is (git rev-parse --show-toplevel
), and try the path relative to that root.