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

AW: Updatable svn export

From: Markus Schaber <m.schaber_at_codesys.com>
Date: Tue, 9 Jul 2013 15:06:19 +0000

Hi, David,

Von: David Schweikert [mailto:david_at_schweikert.ch]
> We have a svn repository with many files (more than 30'000), and need to have
> the HEAD version exported to a filesystem, whenever a commit is done.
>
> Currently, we have implemented this with a post-commit script that does a
> "svn update", but the script is rather slow. The reason is that "svn update"
> apparently checks the whole tree for any local changes. In our case, we can
> however guarantee that no changes are done in the working copy.
>
> I was thinking that we could use something like a "svn update --readonly",
> where svn doesn't any check anything on the working copy, but just applies
> any changes committed since the last update.
>
> An alternative would be to implement a special mode for "svn export", which
> writes a file with the exported revision number (".revision" in the root
> directory, for example), and a "svn export-update" that only fetches any
> changed files between the last exported version and HEAD. It could even be a
> completely separate binary which uses libsvn...
>
> What are your thoughts on this? We have computer engineering students that
> could be put on such a project, but it would be great to have some guidance
> on whether this is a good idea and what you would recommend doing.

A tool like this should be reasonably easy to implement using the SVN APIs
(or language bindings). You could fetch the log, check which pathes are
added/removed/changed, and fetch the added/changed files via "cat"
functionality.

However, if your files are big and the network is slow, this might be
actually much slower than update, because it transfers the whole files
instead of just the differences.

Best regards

Markus Schaber

CODESYS(r) a trademark of 3S-Smart Software Solutions GmbH

Inspiring Automation Solutions

3S-Smart Software Solutions GmbH
Dipl.-Inf. Markus Schaber | Product Development Core Technology
Memminger Str. 151 | 87439 Kempten | Germany
Tel. +49-831-54031-979 | Fax +49-831-54031-50

E-Mail: m.schaber@codesys.com | Web: http://www.codesys.com | CODESYS store: http://store.codesys.com
CODESYS forum: http://forum.codesys.com

Managing Directors: Dipl.Inf. Dieter Hess, Dipl.Inf. Manfred Werner | Trade register: Kempten HRB 6186 | Tax ID No.: DE 167014915
Received on 2013-07-09 17:06:53 CEST

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