I like it when people email me cool stuff. Today Jon emailed me about adding his new project SvnTask to my Ant wiki.
SvnTask is a super simple solution for using svn from ant. I just want a 100% Java solution that uses the nice svnkit library. Include two simple jar files and go.
I haven’t tried it yet but will give it a shot tomorrow! It’s open-source and hosted on Google Code so you can checkout the code and contribute your own patches.
jim, will you post back here with your thoughts? i’m curious to see how well it works for you.
thanks!
Sure! Not sure if it’s going to be today or not… Working on a 2300 line spaghetti file.
Hey Jim, can you post more examples of an ANT sync between two windows machines? I can sync just fine in ANT on the same box but not sure how to sync between two different machines using an ANT build file.
@Noah – how are you connected between the two machines? FTP? Mapped drive? There are several tasks in Ant that should be able to handle any kind of file transfer…
We have a collection of Windows servers on our internal network. We export our SVN repository on the local server just fine and then would like to copy that export to another machine. We have mapped drives but they don’t seem to work in ANT. Any suggestions?
So you have Server A which has your SVN Repo.
You want to export a project from Server A to Server B?
I don’t know what I was doing wrong, but it was as simple as just mapping a drive and then calling it in my fileset.
This is a test
Thanks for asking if I was using a mapped drive. It was that easy.
@Noah – glad you got it working!
The only problem I have with this is that it requires a user logged into the server for the mapped drives to work. I have my ANT tasks running automatically 4 times a day and the server is sometimes locked. When this happens then the mapped drives don’t work, am I missing something?
I’m assuming your Ant tasks are running on a workstation somewhere? Have you considering moving it to the server?
We are running our Ant tasks on a Windows 2003 server on our internal network. It works great when we are logged in but we don’t want to have the server logged in all the time. We would prefer it locked most of the time unless one of our IT staff is using it.
Hmmm – that I’m at a loss how to fix. :(
I figured it out by just calling it by machine name.
using the destination directory as \\testserver\directory path seemed to work. Just don’t forget to make sure the directory has the correct permissions to allow for the sync.
Hope this helps.
So using a UNC path works while you are not logged in to the server?
it appears so, it seems that calling a mapped path like for example: G:\test\builddir will only work when you are logged in for that mapped drive to take effect. The UNC seems to work all the time.
I hope this cuts down the headaches for other people that might read this.