[PATCH V2] lfs: add the '{lfsattrs}' template keyword to '{lfs_files}'

Matt Harbison mharbison72 at gmail.com
Mon Jan 22 18:08:40 EST 2018



> On Jan 22, 2018, at 5:51 PM, Martin von Zweigbergk <martinvonz at google.com> wrote:
> 
> 
> 
>> On Mon, Jan 22, 2018 at 12:21 PM, Matt Harbison <mharbison72 at gmail.com> wrote:
>> 
>> > On Jan 22, 2018, at 12:24 PM, Martin von Zweigbergk <martinvonz at google.com> wrote:
>> >
>> >> On Fri, Jan 19, 2018 at 10:34 PM, Matt Harbison <mharbison72 at gmail.com> wrote:
>> >>> On Fri, 19 Jan 2018 07:21:30 -0500, Yuya Nishihara <yuya at tcha.org> wrote:
>> >>>
>> >>>> On Fri, 19 Jan 2018 00:05:42 -0500, Matt Harbison wrote:
>> >>>>
>> >>>> # HG changeset patch
>> >>>> # User Matt Harbison <matt_harbison at yahoo.com>
>> >>>> # Date 1515967224 18000
>> >>>> #      Sun Jan 14 17:00:24 2018 -0500
>> >>>> # Node ID fccf09e44f5124abf18ae898fab553ea6d91e951
>> >>>> # Parent  45b678bf3a787085d56fad5bee494e0c160aa120
>> >>>> lfs: add the '{lfsattrs}' template keyword to '{lfs_files}'
>> >>>
>> >>>
>> >>> Queued updated version, thanks.
>> >>>
>> >>>> I liked {pointer} better, but couldn't make it work with the
>> >>>> singular/plural
>> >>>> forms.
>> >>>
>> >>>
>> >>> I think {pointer} is okay here since its singular form is ({key},
>> >>> {value}).
>> >>
>> >>
>> >> OK, I'll rename after the freeze.
>> >
>> > Sorry, I found this discussion only now. I'm a little worried that
>> > {pointer} is too generic. There's no indication that it has anything
>> > to do with lfs, and I suppose it does mean that we can't use {pointer}
>> > for something in core later. If something outside of core would want
>> > to use use it, that's less of a concern, because that other thing
>> > could just include a prefix (e.g. {rflpointer} for something in
>> > remotefilelog). I'm not too worried about it, but I thought I'd
>> > mention it.
>> 
>> Fair point. The revelation that this could be an attribute of core file templates came late to me.  Do you want to try to slip in a rename to “lfs_pointer” or similar before the -rc tag drops?  It will be several hours before I can do that.
>> 
> 
> The other discussion in this thread made me wonder if {pointer} is just applicable in the {lfsattrs} context (i.e. something like '{lfsattrs % {pointer}}'). If that's the case, I have no problem with calling it just {pointer}.

It’s currently meant for {lfs_files % {pointer}}, but Yuya asked that I change the {lfs_file} sub-keyword to {file} for consistency with the core templates.  It seems reasonable that this should be something that could be added to the core templates without renaming too.

I submitted the patch, so at least there’s options now.  I don’t want to be the one delaying the rc.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.mercurial-scm.org/pipermail/mercurial-devel/attachments/20180122/815415ed/attachment.html>


More information about the Mercurial-devel mailing list