qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH] scripts: add "git.orderfile" for ordering diff


From: Laszlo Ersek
Subject: Re: [Qemu-devel] [PATCH] scripts: add "git.orderfile" for ordering diff hunks by pathname patterns
Date: Fri, 2 Dec 2016 13:11:24 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.5.1

On 12/02/16 11:59, Gerd Hoffmann wrote:
>>   git config diff.orderFile scripts/git.orderfile
> 
>> diff --git a/scripts/git.orderfile b/scripts/git.orderfile
>> new file mode 100644
>> index 000000000000..600a2e4fc540
>> --- /dev/null
>> +++ b/scripts/git.orderfile
>> @@ -0,0 +1,15 @@
> 
> Is it possible to have comments in here?  So we can place the git config
> command above into into this file too?

The documentation is silent on this, and I didn't want to experiment, so
I checked the git source code. Yes, comments seem to be supported, see
the prepare_order() function in "diffcore-order.c":

                        /* cp to ep has one line */
                        if (*cp == '\n' || *cp == '#')
                                ; /* comment */

How about the following comment:

# Apply this diff order to your git configuration with the command
#
#   git config diff.orderFile scripts/git.orderfile

?

Thanks
Laszlo

>> +*.txt
>> +configure
>> +GNUmakefile
>> +makefile
>> +Makefile
> 
> We also have Makefile.objs and Makefile.target, so "Makefile*" (like the
> first version had IIRC) should work better.
> 
>> +*.mak
>> +qapi-schema*.json
>> +qapi/*.json
>> +include/qapi/visitor.h
>> +include/qapi/visitor-impl.h
>> +scripts/qapi.py
>> +scripts/*.py
>> +*.h
>> +qapi/qapi-visit-core.c
> 
> I guess there is more which could be placed here (i.e. files holding
> infrastructure which makes sense to see first).  But we can easily
> refine that incrementally.  That is the point to have this file in the
> repo in the first place ;)
> 
> cheers,
>   Gerd
> 
> 




reply via email to

[Prev in Thread] Current Thread [Next in Thread]