Doug Robinson wrote on Fri, 13 Dec 2019 21:59 +00:00:
> If I [...] edit that patch file using an editor with settings that replace 
> the TAB 
> with a "proper" number of SPACE characters,

Don't do that.  If the context lines start with tabs (ignoring the first
column), they would be corrupted and the patch wouldn't apply — and even
if it did apply, the indentation would be off-by-one or off-by-eight.  However:

> $ svn patch ../n.txt 
> Skipped missing target: 'TheFile (revision 18)'
> Summary of conflicts:
>  Skipped paths: 1
> 
> (the TAB was between "TheFile" and "(revision...)".

Fixing this specific case would be helpful to projects that use spaces-
only indentation where the unidiff got tabs-to-spaces'ed at some point
(e.g., some terminal emulators do this).  I'm not opposed to it, though
I don't think it's high priority either.  Does anyone have an algorithm
to propose?  (An algorithm for deriving the name of a file to patch from
the +++, ---, and "Index:" lines.)

Cheers,

Daniel

Reply via email to