cmdserver: set current process folder to a repository root after startup

Matt Mackall mpm at
Fri Feb 17 09:39:38 CST 2012

On Fri, 2012-02-17 at 10:48 +0400, Sergey Antonov wrote:
> When I run hg in cmdserver mode it treats the paths relative to the 
> process current folder (like standalone hg).
> So, if I get some path from a changeset description (i.e. 
> Folder/foobar.txt) the cmdserver does not accept it. I need either make 
> it a full path or relative to process current folder.

Or add 'path:' to it. From 'hg help patterns':

    To use a plain path name without any pattern matching, start it with
    "path:". These path names must completely match starting at the current
    repository root.

$ cd hg/mercurial
$ hg log | wc
   5513   22378  203124
$ hg log mercurial/ | wc
      0       0       0
$ hg log path:mercurial/ | wc
   5513   22378  203124

Mathematics is the supreme nostalgia of our time.

More information about the Mercurial-devel mailing list