[PATCH 1 of 1 default] hgweb: column / side-by-side diff functionality
Wujek Srujek
wujek.srujek at googlemail.com
Mon Jun 11 13:52:55 UTC 2012
I would like to do it as for example the 'style' setting: the user can
define it in hgrc, but can also override it via a URL parameter (that's
also what I implemented in the previous patch, for full / short). If there
is need for some dropdown or sth, it will then be easy to implement, but I
won't do it in the first version.
wujek
On Mon, Jun 11, 2012 at 3:13 PM, Laurens Holst <laurens.nospam at grauw.nl>wrote:
> Op 11-06-12 15:04, Patrick Mézard schreef:
>
> Le 11/06/12 14:57, Laurens Holst a écrit :
>>
>>> Op 11-06-12 14:36, Patrick Mézard schreef:
>>>
>>>> Le 11/06/12 12:09, Laurens Holst a écrit :
>>>>
>>>>> Actually ideally you would be able to variably specify the amount of
>>>>> context with an URL parameter. context=3 (default), context=5 (more),
>>>>> context=full (complete).
>>>>>
>>>> Sounds good to me.
>>>>
>>>> Wujek, what do you think about replacing `fullcoldiff` with
>>>> `fullcolcontext` or `comparisoncontext`, where a negative value would mean
>>>> everything and a positive or nul one would be the maximum number of context
>>>> lines surrounding the blocks? (SequenceMatcher.get_grouped_**opcodes(n)
>>>> supports this since 2.3, should not be too hard to change).
>>>>
>>> Not my call obviously, but just a note that I think "comparisoncontext"
>>> is unnecessarily verbose compared to just "context" (the subject -a
>>> column-diff- is already clear from the base URL so no need to repeat it),
>>> and also that it’s nicer to use a "full" keyword instead of a "-1" magic
>>> number whose meaning is not as apparent. HTTP won’t mind ;p.
>>>
>> I was considering the configuration entry rather, not the HTTP parameter.
>> "context" is bit more ambiguous in [web] section.
>>
>> I think handling negative value as "full" can be convenient, it lets the
>> parameter have a single simple type. "full" could be supported, it just
>> requires a little more work when parsing it, which can be done later.
>>
>
> Ah! I was thinking of an URL parameter with corresponding drop-down box.
> Given that I would want it to default to little context (~3 lines), but
> change it as needed to provide more.
>
> Btw, the context parameter could apply not only to column diffs but also
> to plain old diffs. Maybe that’s something to consider when
> naming/implementing.
>
> ~Laurens
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mercurial-scm.org/pipermail/mercurial-devel/attachments/20120611/d29e83ef/attachment-0002.html>
More information about the Mercurial-devel
mailing list