5 # one-time conversion of SVN repositories to Git repositories
7 # Copyright © 2006–2009 martin f. krafft <madduck@madduck.net>
8 # Released under the terms of the Artistic Licence 2.0
10 # Source repository: git://git.madduck.net/etc/zsh.git
13 local svnrepo dest args
18 (svn+*|svn://|http://)
19 if [[ -z $svnrepo ]]; then
22 echo "E: SVN repository multiply defined." >&2
27 if [[ -e $dest ]]; then
28 if [[ -d $dest ]] && [[ -z $svnrepo ]] && svn info $svnrepo >/dev/null 2>&1; then
31 echo "E: destination $dest already exists." >&2
35 if [[ -z $dest ]]; then
44 git svn clone --no-metadata $args "$svnrepo" "$dest"
48 test -d svn && rm -r svn