0
votes

I've looked at tfs2svn and SvnBridge but neither are quite what I'm looking for.

We have our project source code in TFS, but our client wants nightly copies of the source code pushed to their own SVN remote repository.

I've come across git-tfs which is a two way bridge between Git and TFS and git-svn which is a similar two way bridge between Git and SVN. I guess I could combine the two in a workflow, but a direct svn-tfs would be the neater solution!

Alternatively, can the source code be part of two separate source control repository types similtaneously?

Has anyone else had a similar requirement and solved the problem?

1
What did you try with SvnBridge? - PatrickLu-MSFT

1 Answers

0
votes

You can try this workaround: cloned TFS to GIT and pushed GIT repo to SVN. You can achieve this by a ps script. Below is an opposite script(From SVN-GIT-TFS) for your reference:

for i in "${!SVN_TRUNK[@]}"
do
    mkdir ${GIT_REPO[$i]}
    cd ${GIT_REPO[$i]}      
    fromRevision=$(svn log -l 1 -r{2013-06-01}:HEAD ${SVN_TRUNK[$i]} | awk '/^r[0-9]+/ {sub(/r/,"",$1); print  $1}' )
    toRevision=$(svn info -rHEAD ${SVN_TRUNK[$i]} | grep Revision | cut -d' ' -f2)

    git svn init ${SVN_TRUNK[$i]} --no-metadata
    echo 'svn fetch ' ${GIT_REPO[$i]} ' from ' $fromRevision ' to ' $toRevision
    git svn fetch -r $fromRevision:$toRevision

    git tf configure http://tfs:8080/tfs/defaultcollection '$/Portfolio Implementation/Versions/Iteration36RC/'${GIT_REPO[$i]}
    git tf checkin --deep
    cd ..
done