[PATCH 1 of 4 Series-B] clfilter: enforce hidden changeset globally
Pierre-Yves David
pierre-yves.david at logilab.fr
Tue Jan 8 12:49:08 CST 2013
On Tue, Jan 08, 2013 at 12:43:29PM -0600, Kevin Bullock wrote:
> On Jan 8, 2013, at 7:04 AM, pierre-yves.david at logilab.fr wrote:
>
> > # HG changeset patch
> > # User Pierre-Yves David <pierre-yves.david at logilab.fr>
> > # Date 1357580178 -3600
> > # Node ID a342ff119d504e34d22c5ad52a172d6addf121db
> > # Parent b92288b31fc0c2099068928a7a0ef36cd2dc5a6d
> > clfilter: enforce hidden changeset globally
> [...]
>
> > diff --git a/mercurial/dispatch.py b/mercurial/dispatch.py
> > --- a/mercurial/dispatch.py
> > +++ b/mercurial/dispatch.py
> > @@ -708,10 +708,14 @@ def _dispatch(req):
> > else:
> > try:
> > repo = hg.repository(ui, path=path)
> > if not repo.local():
> > raise util.Abort(_("repository '%s' is not local") % path)
> > + if not options['hidden']:
> > + repo = repo.filtered('hidden')
> > + else:
> > + repo = repo.unfiltered()
>
> Can't we assume that hg.repository() will return an unfiltered repo, and leave off the 'else:' clause?
Probably, but I'm -0 for it:
- Explicit is better than implicite
- Better safe than sorry.
Some extensions could mess with that.
> Looks okay to me other than that (and the duplicated computeunserved function
> I mentioned before), but I'd like at least one other set of crew eyes on it.
With you request a resent with `computeunserved` dropped or can you uncommit it
yourself.
--
Pierre-Yves David
http://www.logilab.fr/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://selenic.com/pipermail/mercurial-devel/attachments/20130108/2bda5c16/attachment.pgp>
More information about the Mercurial-devel
mailing list