Repo-relative indicator

Stephen Lee sphen.lee at gmail.com
Mon Nov 25 19:48:45 CST 2013


On Tue, Nov 26, 2013 at 12:38 PM, Bosco Rama <hg at boscorama.com> wrote:
> Hey,
>
> I have a strange question:  Is there a repo-relative indicator for
> command-line paths similar to the bash '~' character?  Several times
> recently I've been several levels deep in a different part of the tree
> and have wanted to generate a 'hg diff' of a file in another part of the
> tree.  So, I either have to use a bunch of '..'s or use an absolute
> path to do this.  Short of setting my own '$repo' shell var and using
> that do I have any other options within hg?
>

You can use `hg root`, or $(hg root) in bash.

Steve


More information about the Mercurial mailing list