On Thu, Mar 04, 2010 at 08:49:49AM +0000, icm wrote:
> Ian Mockford writes:
> > [...]
> > > The problem seems to be that enforcer always expects a "diff" output
> > > following the file rename, but if the file is empty, svnlook diff
> > > shows no diff output bars.
> > >
> > > (enforcer using svnlook version 1.6.9 (r901367), on Windows XP)
> > >
> > > Can anyone confirm this is a bug?
> > > Or a possible change to svnlook output format?
> My summary of the situation, for the record:
> contrib\hooks\enforcer seems to struggle with empty files when using svnlook
> I can't find if/how/where or rather, by whom, the contribs are maintained.
> v1.6.5 includes this change:
> "make 'svnlook diff' show empty added or deleted files (r38458)"
> - so that might be where the change happened. But r38458 description
> includes the following:
> "If we don't print any output for empty added or deleted files,
> hook scripts relying on 'svnlook diff' to gather information about
> files affected by a revision can get confused.
> E.g. contrib/hook-scripts/enforcer is known to be affected,
> it cannot enforce rules on added empty files."
> I can't find any record of "E.g. contrib/hook-scripts/enforcer is known to be
> Hopefully one day someone who knows more about it will be able to confirm this
> as a problem in either svnlook or the enforcer script and possibly and fix one
> of them. If I could be sure that it was enforcer rather than svnlook that was
> wrong I could have a go at fixing it myself.
I made this fix to svnlook in 1.6.5.
I think the user who reported this problem reported it on IRC,
so you'd have to search the log of the #svn IRC channel to find
a record of the statement that "enforcer is known to be affected".
I had the user test the patch and has said it fixed his particular problem.
From what you describe it sounds like enforcer is still broken in
some way and needs some kind of fix. I'd encourage you to try to fix
this yourself and submit a patch if you can.
Received on 2010-03-04 11:19:41 CET