[PATCH] commands: add support for 'hg log -b .' (issue2078)
Matt Mackall
mpm at selenic.com
Mon Apr 12 18:56:00 CDT 2010
On Mon, 2010-04-12 at 19:35 -0400, Steve Losh wrote:
> # HG changeset patch
> # User Steve Losh <steve at stevelosh.com>
> # Date 1271115205 14400
> # Node ID 1af118b5a168a1284eada2e993f1177d9f144bd6
> # Parent 3a1a1077f1777396ffbaba9c0cfc307af17ccc36
> commands: add support for 'hg log -b .' (issue2078)
>
> Fixes issue2078 and adds tests to cover various 'hg log -b' uses.
>
> The long line just barely passes check-code, but there might be a better way
> to do it.
I think this should be more generic. '-b .' should read as 'the branch
that the working directory is on' so '-b <rev>' should similarly read as
'the branch <rev>' is on. In other words:
branch = repo[rev].branch()
And this should eventually work wherever we take a <branch> argument:
-r <branch> -> revision at tip of <branch> (we do this now)
-b <rev> -> branch containing <rev>
Special-casing it for '.' is ugly.
--
http://selenic.com : development and support for Mercurial and Linux
More information about the Mercurial-devel
mailing list