From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: AS31976 209.132.180.0/23 X-Spam-Status: No, score=-3.9 required=3.0 tests=AWL,BAYES_00, FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM,HEADER_FROM_DIFFERENT_DOMAINS, RCVD_IN_DNSWL_HI,RP_MATCHES_RCVD shortcircuit=no autolearn=ham autolearn_force=no version=3.4.0 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by dcvr.yhbt.net (Postfix) with ESMTP id 78DDB20958 for ; Thu, 23 Mar 2017 19:30:56 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751449AbdCWTat (ORCPT ); Thu, 23 Mar 2017 15:30:49 -0400 Received: from mout.web.de ([212.227.15.14]:59781 "EHLO mout.web.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750952AbdCWTas (ORCPT ); Thu, 23 Mar 2017 15:30:48 -0400 Received: from [192.168.178.36] ([79.213.126.222]) by smtp.web.de (mrweb003 [213.165.67.108]) with ESMTPSA (Nemesis) id 0Lpw63-1cDQBB0wJL-00fjg4; Thu, 23 Mar 2017 20:30:42 +0100 Subject: Re: Question: libxdiff: text-patches: internal format To: matthew@giassa.net References: <20170323180026.7qdfdzqgyczt2s3f@darkstar> From: =?UTF-8?Q?Ren=c3=a9_Scharfe?= Cc: git@vger.kernel.org Message-ID: Date: Thu, 23 Mar 2017 20:30:41 +0100 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.8.0 MIME-Version: 1.0 In-Reply-To: <20170323180026.7qdfdzqgyczt2s3f@darkstar> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 8bit X-Provags-ID: V03:K0:Rz6el00mPIe/wyJbYW61vxY7hNdHKvDrRiygsvcN4SvWHua306r FYUhq9xXHZVyAHTcQxvt3ZsJ+FXZTKKsjuXMAxCFm+xqkTNWM5kk2IBVGctoftNeytQ5NvL US6O2PRpw5wyipqpVd2I6HAiF+mzXAAzhPq13kKhegJ0BThDgZlA5nhDPtVT3p4F+FqkrR8 gn2V3mV1ugbeeJatX0EXw== X-UI-Out-Filterresults: notjunk:1;V01:K0:VUyy8dFY2KQ=:e50arflB4RTospoQ02xg5J bNG7NKIDK0v0pu3hqHuJFFUo9RRvL1NkmFKrTSo0w48V1WpEjSUrJIipts31AnCdFtvg0M2hl AUPeJdR4JLHWTfvu1G1WHO2pM88OV/2NLJ1TFzMx/D3zM7zupXTSfLOb/z25sUIc2cgj+FXJX rgvbj6RkS030DEpG/CgxMIby+caQxBc3KfixiH21PjWCoVOKrp+K8yaaCZQ4ZavhyI+je2w52 WycKEAsrAhM3w3t5HTJn48lTxJ71mFkhJWlrWe2rynvZFmkda3den6SkuBxE2c7xWaBiQ8OTX nxJhkAvWshQM8AaxSLaJHzeX0r2CbNb1Kph+ycGk3vfHkz2CeXZLmzlDzx543KWIq/0W2KN2v btYctGJ+XdfiLP9W6eNRPlEF98fgxQVwwVsZRxKGmt7uufJeHHDNXulAljnc47w5eKutw8rkv HCFQ7MD5lxelNYvmfMXZ2YNqag9tDsEt2whsLbAKAwouX/cKT3RAmZp0XCbPr0GN6X96iQVLj JoCMSJEQIdisImbvPMtv1vyynOFDf4FAii6BHbmTo+j1HG9cNh90GMeqxS+JgiL1TZoaQvLF3 /DKtdFB37/bva4vAsvuNP/E9aOs5fs/1OZRglj28/k1O4V8+U4kHejvP1exUzf6TuWIp+iB37 G9bqDV4Lvq+TfUh1gODN9mGxZTkPHa8dh5vdbkHta524GHSsfTfD/4bdu31LdcM7A2qTJ2zwD dAWP9I2rfu/yLjJJndyVc+9bCng83hYlg/+fPhoFgnDRvM27PDLcpEtsPoaYKrG8JwYUjAGGb qhFkTlj Sender: git-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org Am 23.03.2017 um 19:00 schrieb matthew@giassa.net: > Hi there, > > Following up on an earlier question of mine from yesterday, is there any > formal documentation (save for source diving) on the internal format > used by libxdiff/xdiff when it generates a patch by comparing two > plaintext files? > > I'd like to generate a human-readable "pretty" diff from the output > generated by libxdiff, and while the suggestion by Stefan yesterday is a > good idea (ie: go through diff.c), I'm trying to see if there's a > quicker way to pull this off. Also, I can't determine if lifting that > code from git would invoke LGPL licensing constraints (no problem), or > GPL licensing constraints (incompatible with my application). If the > format is easy enough to follow, I might just write my own parser, > provided it's a trivial task. Some of your questions may be answered on the homepage of LibXDiff, http://www.xmailserver.org/xdiff-lib.html. That's the original version that was imported into Git long ago. It lacks some Git-specific features, but the documentation and links on the web page may still help you. The original LibXDiff is licensed under the LGPL and perhaps you can use it directly already. René