Branko Čibej wrote: > On 13.06.2012 16:33, Julian Foad wrote: >> I think this is a valid enhancement request: to have an API to get the >> WC base tree (not what the UI calls "base", but the result of the last >> checkout/update, which is called BASE (usually with capital letters) >> in libsvn_wc). By "get the tree" I mean an API that covers getting the >> directory tree structure, text and properties, and also perhaps other >> relevant metadata such as revision numbers, last-changed info, etc. > > You're overreacting to their request,
Yes, you're right; I should have put my pet project ideas in a new email thread, not here. But my main point is that *if* there is missing API functionality then it's perfectly reasonably to request for the missing bit to be filled in. (I haven't checked for myself that it really is missing functionality.) > as you note below. There's also > this thing called "svn diff" that already tells you everything you > need to know about the changes in the working copy. > >> We could of course just add one function that does the specific thing that >> you have found to be missing. > > I don't believe this project should be in the business of helping people > to avoid using a version control system. I totally agree, but we should present a complete logical interface to the SCM. > However, I shall now > demonstrate that Subversion already provides that functionality: This demo doesn't seem to include the replacement of a node, which is the case in question. - Julian > brane@zulu$ svnadmin create r > brane@zulu$ svn co file://`pwd`/r w > Checked out revision 0. > brane@zulu$ cd w > brane@zulu/w$ echo foo > f > brane@zulu/w$ svn add f > A f > brane@zulu/w$ svn ci -m '' > Adding f > Transmitting file data . > Committed revision 1. > brane@zulu/w$ echo bar >> f > brane@zulu/w$ svn diff > Index: f > =================================================================== > --- f (revision 1) > +++ f (working copy) > @@ -1 +1,2 @@ > foo > +bar > brane@zulu/w$ svn cat f > g > brane@zulu/w$ diff -u f g > --- f 2012-06-13 16:38:49.000000000 +0200 > +++ g 2012-06-13 16:39:01.000000000 +0200 > @@ -1,2 +1 @@ > foo > -bar > brane@zulu/w$ > > > -- Brane >