DPDK patches and discussions
 help / color / mirror / Atom feed
From: Thomas Monjalon <thomas.monjalon@6wind.com>
To: Ferruh Yigit <ferruh.yigit@intel.com>
Cc: dev@dpdk.org
Subject: Re: [dpdk-dev] [PATCH] improve git diff
Date: Sat, 12 Nov 2016 21:51:21 +0100	[thread overview]
Message-ID: <3760690.4pEarhzBJZ@xps13> (raw)
In-Reply-To: <59b9b8bf-1b90-8055-74f7-eecd6fe9c41a@intel.com>

2016-11-11 17:28, Ferruh Yigit:
> On 11/11/2016 4:21 PM, Thomas Monjalon wrote:
> > 2016-11-11 11:22, Ferruh Yigit:
> >> On 11/9/2016 3:44 PM, Thomas Monjalon wrote:
> >>> Sometimes git does not print the name of the function being changed
> >>> after @@. It happens especially after a goto label which is not indented.
> >>> Giving a hint about the languages of files .c, .h and .py
> >>> will improve hunk headers of "git diff" rendering.
> >>>
> >>> Signed-off-by: Thomas Monjalon <thomas.monjalon@6wind.com>
> > [...]
> >>> --- /dev/null
> >>> +++ b/.gitattributes
> >>> @@ -0,0 +1,3 @@
> >>> +*.c   diff=cpp
> >>> +*.h   diff=cpp
> >>
> >> Can't git auto detect to use C/C++ language diff use for .c/.h files?
> > 
> > No
> > 
> >> Do you have a sample that generates bad hunk header, just to test?
> > 
> > Yes, you'll find a lot of them with "git log -p | grep '@@.*:'"
> > Example:
> > 	git show bb6722f | grep '@@.*:'
> > Without the patch, it is a goto label in the hunk header.
> > 
> 
> You are right, I was expecting better from git J

Sometimes, less is more :)

  reply	other threads:[~2016-11-12 20:51 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-11-09 15:44 Thomas Monjalon
2016-11-11 11:22 ` Ferruh Yigit
2016-11-11 16:21   ` Thomas Monjalon
2016-11-11 17:28     ` Ferruh Yigit
2016-11-12 20:51       ` Thomas Monjalon [this message]
2016-11-13 14:21 ` Thomas Monjalon

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=3760690.4pEarhzBJZ@xps13 \
    --to=thomas.monjalon@6wind.com \
    --cc=dev@dpdk.org \
    --cc=ferruh.yigit@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).