[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: [PATCH] - svn blame doesn't use the working revision (Issue 1777)

From: <kfogel_at_collab.net>
Date: 2004-04-16 17:23:57 CEST

John Szakmeister <john@szakmeister.net> writes:
> > Log Message:
> > Fix Issue #1777: 'svn blame' should default to the working revision,
> > when no revision is specified.
> >
> > * subversion/clients/cmdline/blame-cmd.c
> > (svn_cl__blame) : Set opt_state->end_revision.kind
> > to svn_opt_revision_base,to ensure 'svn blame' defaults to base
> > revision.
> Small problem here. This breaks using a URL without specifying a revision.
> With your patch I get the following when trying to use a URL instead of a
> working copy path:
> :: svn blame file://`pwd`/repo/A
> subversion/libsvn_wc/lock.c:373: (apr_err=155007)
> svn: 'file:///home/jszakmeister/projects/tmp/repo' is not a working copy
> I think the best solution here would be to let svn_client_blame()
> resolve the start and end revision if it's unspecified. This
> changes the API a little, so the earliest it could make it into a
> release would be 1.1 (which is where the issue put it anyways).
> Would you mind taking another stab at this but fixing
> svn_client_blame() instead?

That would mean creating svn_client_blame2(), at least until 2.0.
(See the subsection "Deprecation" in HACKING for details.)

Instead, why not take Ramaswamy's patch a bit further:

svn_cl__blame should set to svn_opt_revision_base if the target is a
local path, or to svn_opt_revision_head if target is a URL. That way,
no modifications to svn_client_blame() are necessary right now.

We can, if we want, file a 2.0 issue to change that interface promise
in svn_client_blame(), have it behave as you imply, and adjust
svn_cl__blame() accordingly. But, I don't think we need to bother
with the svn_client_blame2() intermediate step right now, when we can
solve it in the caller pretty easily.


To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Fri Apr 16 18:39:16 2004

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.