git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: kompare won't parse git diffs

From
Jakub Narebski <jnareb@gmail.com>
Date
Aug 2, 2006, 18:12 UTC
Message-ID
<eaqpt2$ots$1@sea.gmane.org>
In-Reply-To
<Pine.LNX.4.64.0608021006150.4168@g5.osdl.org>
Linus Torvalds wrote:
Show 15 quoted lines
> On Wed, 2 Aug 2006, Andy Parkins wrote:
>>
>> Kompare just shows blank for diffs redirected from git. [ snip ]
>> 
>> As you can see, it's a simple addition of the line "blah".  Kompare shows this 
>> diff as blank.  Now if I modify the file so that the "---" and "+++" lines 
>> both have "<tab>(something)" added:
> 
> I'd definitely call this a pure kompare bug.
> 
> Not only is the git patch format perfectly standard and accepted by other 
> tools, it's much better designed than the brain-damaged syntax that GNU 
> patch uses (which adds a tab and a timestamp after the filenames). In 
> particular, with git patches it is easy to get filenames that have spaces 
> and tabs in them right. 
What about filenames with end-of-line character in them? Is it quoted?

BTW. It should be not that hard to get filename with spaces and tabs even in GNU diff format: everything up to last <tab> is filename.

Show 5 quoted lines
> Now, if the kompare people can show that every single other patch 
> generator adds the stupid tab + date format, I guess we could do it too, 
> but
>  (a) there is no valid date in general to use, so it's a fundamentally 
>      broken notion and

Meaning we don't save timestamp in git ;-) Well, we could use date of the commit which created given file contents (first commit from root, or last from head which contains given version)... but the same contents might be introduced independently in different commits. And different clones of the same repository might have different commit dates...

-- 
Jakub Narebski
Warsaw, Poland
ShadeHawk on #git
Previous: Linus TorvaldsNext: Junio C Hamano
Message 3 of 9 in “kompare won't parse git diffs”
  1. Andy ParkinsAug 2, 2006
  2. Linus TorvaldsAug 2, 2006
  3. Jakub NarebskiAug 2, 2006
  4. Junio C HamanoAug 2, 2006
  5. Paul EggertAug 6, 2006
  6. Linus TorvaldsAug 2, 2006
  7. Jakub NarebskiAug 2, 2006
  8. Linus TorvaldsAug 2, 2006
  9. Andy ParkinsAug 2, 2006

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.