You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Sander Striker <st...@apache.org> on 2002/04/23 20:20:39 UTC

Diff lib commit, WAS: RE: svn commit: rev 1752 - trunk/subversion trunk/subversion/include trunk/subversion/libsvn_diff

> From: striker@tigris.org [mailto:striker@tigris.org]
> Sent: 23 April 2002 22:03

> Author: striker
> Date: 2002-04-23 20:02 GMT
> New Revision: 1752
> 
> Added:
>    trunk/subversion/include/svn_diff.h
>    trunk/subversion/libsvn_diff/
>    trunk/subversion/libsvn_diff/diff.c
> Log:
> Initial commit of the diff lib.

Some notes on this initial commit.  We can do a lot better when it
comes to conflict resolution.  No need to do the 'hunk' thing.  
However, this introduces a problem in the API (output).  IOW, this
needs some thought.  There is a big fat comment at the location where
the improvement can be done.

Things to be done:
 - add comments
 - add wrappers (svn_diff_file, svn_diff3_file, svn_diff_output_unified)
 - do better conflict resolution
 - write tests
 - investigate if the support structs/funcs (the hat stuff) can
   be replaced with apr support structs/funcs.

This patch enables the diff lib build:

Index: ./build.conf
===================================================================
--- ./build.conf
+++ ./build.conf        Sat Apr 13 14:11:51 2002
@@ -103,6 +103,13 @@
 path = subversion/libsvn_delta
 libs = libsvn_subr $(SVN_APR_LIBS)

+# Routines for diffing
+[libsvn_diff]
+type = lib
+install = base-lib
+path = subversion/libsvn_diff
+libs = libsvn_subr $(SVN_APR_LIBS)
+
 # The repository filesystem library
 [libsvn_fs]
 type = lib


I used the attached file for simple testing.

Sander

Re: Diff lib commit, WAS: RE: svn commit: rev 1752 - trunk/subversion trunk/subversion/include trunk/subversion/libsvn_diff

Posted by Branko Čibej <br...@xbc.nu>.
Garrett Rooney wrote:

>On Tue, Apr 23, 2002 at 10:20:39PM +0200, Sander Striker wrote:
>
>>>From: striker@tigris.org [mailto:striker@tigris.org]
>>>Sent: 23 April 2002 22:03
>>>
>>>Author: striker
>>>Date: 2002-04-23 20:02 GMT
>>>New Revision: 1752
>>>
>>>Added:
>>>   trunk/subversion/include/svn_diff.h
>>>   trunk/subversion/libsvn_diff/
>>>   trunk/subversion/libsvn_diff/diff.c
>>>Log:
>>>Initial commit of the diff lib.
>>>
>
>first, this is very cool!  i anxiously await the day i can remove the
>GNU diffutils package from my FreeBSD system (since it's only there
>for subversion).
>
>but is there any specific reason diff.c has windows style line
>endings?  i try not to be prejudiced against other platforms, but it's
>kind of jarring to be going through .c files in the tree and all of a
>sudden one of them shows up with ^M's at the end of the lines in vi...
>
Nah, that's just Sander not using Emacs on Windows. :-)

(Y'all gonna learn to appreciate me, heh heh. *evil grin*)

-- 
Brane Čibej   <br...@xbc.nu>   http://www.xbc.nu/brane/




---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

RE: Diff lib commit, WAS: RE: svn commit: rev 1752 - trunk/subversion trunk/subversion/include trunk/subversion/libsvn_diff

Posted by Sander Striker <st...@apache.org>.
> From: Garrett Rooney [mailto:rooneg@electricjellyfish.net]
> Sent: 24 April 2002 00:12

> On Tue, Apr 23, 2002 at 10:20:39PM +0200, Sander Striker wrote:
> > > From: striker@tigris.org [mailto:striker@tigris.org]
> > > Sent: 23 April 2002 22:03
> > 
> > > Author: striker
> > > Date: 2002-04-23 20:02 GMT
> > > New Revision: 1752
> > > 
> > > Added:
> > >    trunk/subversion/include/svn_diff.h
> > >    trunk/subversion/libsvn_diff/
> > >    trunk/subversion/libsvn_diff/diff.c
> > > Log:
> > > Initial commit of the diff lib.
> 
> first, this is very cool!  i anxiously await the day i can remove the
> GNU diffutils package from my FreeBSD system (since it's only there
> for subversion).

heh
 
> but is there any specific reason diff.c has windows style line
> endings?  i try not to be prejudiced against other platforms, but it's
> kind of jarring to be going through .c files in the tree and all of a
> sudden one of them shows up with ^M's at the end of the lines in vi...

Bah.  My linux build broke (stupid expat... *grmbl*), so I used
my windows box to carry on.  I'll fix this soon!
 
> -garrett

Sander

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: Diff lib commit, WAS: RE: svn commit: rev 1752 - trunk/subversion trunk/subversion/include trunk/subversion/libsvn_diff

Posted by Garrett Rooney <ro...@electricjellyfish.net>.
On Tue, Apr 23, 2002 at 10:20:39PM +0200, Sander Striker wrote:
> > From: striker@tigris.org [mailto:striker@tigris.org]
> > Sent: 23 April 2002 22:03
> 
> > Author: striker
> > Date: 2002-04-23 20:02 GMT
> > New Revision: 1752
> > 
> > Added:
> >    trunk/subversion/include/svn_diff.h
> >    trunk/subversion/libsvn_diff/
> >    trunk/subversion/libsvn_diff/diff.c
> > Log:
> > Initial commit of the diff lib.

first, this is very cool!  i anxiously await the day i can remove the
GNU diffutils package from my FreeBSD system (since it's only there
for subversion).

but is there any specific reason diff.c has windows style line
endings?  i try not to be prejudiced against other platforms, but it's
kind of jarring to be going through .c files in the tree and all of a
sudden one of them shows up with ^M's at the end of the lines in vi...

-garrett

-- 
garrett rooney                    Remember, any design flaw you're 
rooneg@electricjellyfish.net      sufficiently snide about becomes  
http://electricjellyfish.net/     a feature.       -- Dan Sugalski

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

RE: Diff lib commit, WAS: RE: svn commit: rev 1752 - trunk/subversion trunk/subversion/include trunk/subversion/libsvn_diff

Posted by Sander Striker <st...@apache.org>.
> From: Sander Striker [mailto:striker@apache.org]
> Sent: 23 April 2002 22:21

[...]
> Things to be done:
>  - add comments
>  - add wrappers (svn_diff_file, svn_diff3_file, svn_diff_output_unified)
>  - do better conflict resolution
>  - write tests
>  - investigate if the support structs/funcs (the hat stuff) can
>    be replaced with apr support structs/funcs.

And some 'long line' cleanups... :(  Sorry.

Sander


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org