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

Re: svnmucc: new commands: add and modify/update

From: sebb <sebbaz_at_gmail.com>
Date: Fri, 24 Jul 2020 00:46:11 +0100

On Thu, 23 Jul 2020 at 23:44, Daniel Shahaf <d.s_at_daniel.shahaf.name> wrote:
>
> sebb wrote on Thu, 23 Jul 2020 11:30 +0100:
> > On Thu, 23 Jul 2020 at 00:59, Daniel Shahaf <d.s_at_daniel.shahaf.name> wrote:
> > >
> > > sebb wrote on Wed, 22 Jul 2020 22:44 +0100:
> > > > The SVN put command can add a new file or update an existing one.
> > > >
> > > > As part of a batch update it may be necessary to ensure that a
> > > > particular file will be created and not updated - or vice versa.
> > > > That is currently not at all easy to do, which is a shame as svnmucc
> > > > is otherwise very useful for writing atomic updates that are not
> > > > possible with the svn client.
> > >
> > > What can svnmucc(1) do that svn(1) can't?
> >
> > Atomic updates.
> >
> > AIUI an svnmucc script only succeeds if all the individual commands succeed.
> >
> > To do that with single commands would require reversion and/or retries.
> >
> > If the reason for an svn client failure is a network or server issue,
> > it's going to be very difficult to tidy up.
>
> You're describing CVS, not Subversion.

No: I'm not referring to tidying up the repository itself, but the
application level inconsistency that can result if a related sequence
of svn commits does not complete.

The issue I am trying to solve is how to ensure related changes to a
subversion repository either all occur or none do.

For example, adding a new file to a directory, and updating a listing
with details of that file.
The file must not already exist. The listing is in a different part of
the repository.

Whilst it would probably be possible to create a sparse checkout of
the different parts of the repository, this is not trivial.

It seems like an ideal job for svnmucc.

However svnmucc does not directly support svn 'add' functionality.

Whilst this can also be worked round, it is quite tedious and easy to get wrong.

I am suggesting that 'add' functionality could be added to svnmucc itself.
This would make it more versatile, especially for use in shell scripts.

(*) I am referring to application-level consistency here, not
consistency of the repository itself.
Received on 2020-07-24 01:46:30 CEST

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