On Fri, Feb 24, 2006 at 05:59:53PM +0100, Albert Reiner wrote: > [Ketil Malde <[EMAIL PROTECTED]>, Fri, 24 Feb 2006 15:04:54 +0100]: > > "Stephen J. Turnbull" <[EMAIL PROTECTED]> writes: > > > > > Ketil> I'm (of course) not saying you should always do word-based > > > Ketil> diffs, only for formats where line-based diffs work poorly. > > > > > How is darcs going to know? I suppose you could teach it, but what's > > > the interface going to be? > > > > Umm...well, either it could select based on file type, or it could be > > a project-wide setting, or both. Theoretically, it could be an > > option, but I think in general, you would choose a mode based on the > > file contents. > > But in literate programming you freely mix program text (where lines > would be appropriate) and (typically TeX-based) descriptive text in > one and the same file (where, presumably, you want to operate on > words). There are other cases where you mix text written in different > languages, which may require different treatment; mmm-mode > <http://sourceforge.net/projects/mmm-mode/> is a way of supporting > that kind of editing in Emacs. > > In these cases, a file is much too coarse a granularity for deciding > whether word or line based diffs are appropriate.
I think it would be nice if the diffing algorithm + interface could select the most likely patch type (line based, word based, move, replace) for every change, and propose that to the user with an option to change patch type to any other possible patch type if the guess was wrong. That would eliminate the required use of explicit darcs commands for producing replace patches &c and one could use ones favorite editor to do all changes. -- Tommy Pettersson <[EMAIL PROTECTED]> _______________________________________________ darcs-users mailing list [email protected] http://www.abridgegame.org/mailman/listinfo/darcs-users
