[PATCH] revset: introduce feature revset for tracking in-progress work (issue4968)

Durham Goode durham at fb.com
Mon Nov 30 17:39:03 CST 2015



On 11/26/15 5:31 PM, Andrew Halberstadt wrote:
> # HG changeset patch
> # User Andrew Halberstadt <ahalberstadt at mozilla.com>
> # Date 1448490626 18000
> #      Wed Nov 25 17:30:26 2015 -0500
> # Node ID 3545b0234e4884f57dac44fd4e443deac5b9d673
> # Parent  61fbf5dc12b23e7a2a30cf04ebd9f096c42a1f61
> revset: introduce feature revset for tracking in-progress work (issue4968)
>
> The revset "only(<rev>) and not public()" is often used to track wip features.
> But this approach is simplistic and doesn't take things like merges,
> obsolescence and bookmarks into account. This change formalizes a 'feature()'
> revset that can turn a set of revision specifications into all the commits
> within their associated feature branches.
>
> A commit C is in the feature ending at revision R if all of the following
> conditions are true:
>
> 1. C is R or C is an ancestor of R
> 2. C is not public
> 3. C is not a merge commit
> 4. C is not obsolete
> 5. no bookmarks exist in [C, R) for C != R
> 6. all commits in (C, R) are also within R for C != R
>
This is awfully specific. What are the use cases that you want to use 
this revset for?

#3 why exclude merge commits if they met all the other criteria?
#5 this implies a certain usage of bookmarks (depending on what your use 
cases for feature() are)


More information about the Mercurial-devel mailing list