Ideas for SVN / WinSCP automation

Advertisement

Philip
Joined:
Posts:
3
Location:
Huntsville, AL, USA

Ideas for SVN / WinSCP automation

I'm trying to improvise a way around my organization's lack of proper source code management (SCM). I've been using Subversion locally, and manually SFTPing changes from the server when I want to place those changes under SVN.

I keep thinking there's got to be a good way to automate this. (Never mind that installing SVN on the server would be far better; so far, that hasn't gotten anywhere.) What I'd like to do is this:

local windows prompt> svn ci foo.txt -m"This is a change."

[WinSCP goes out and gets foo.txt off the server]

Sending foo.txt
Transmitting file data .
Committed revision 1234.

[WinSCP puts the new foo.txt with embedded version info in the $Id$ keyword back on the server.]

I'd probably want to set a flag somehow to make it optional whether I get the server-side version or whether I commit the actual local file.

Any thoughts on how I might go about this? I know SVN hooks are quite powerful but I haven't really played with them. I've done a little bit of WinSCP command line scripting.

Thanks in advance.

Reply with quote

Advertisement

martin
Site Admin
martin avatar
Joined:
Posts:
40,476
Location:
Prague, Czechia

Re: Ideas for SVN / WinSCP automation

I'll think about that. However this is quite complex feature and I do not think I'm going to implement it unless more people ask for that.

Reply with quote

Philip
Joined:
Posts:
3
Location:
Huntsville, AL, USA

Martin,

I wouldn't be surprised if there's a way to do this with existing functionality. I think it's just a matter of passing parameters back and forth among WinSCP, SVN, and the shell (in my case Windows batch files). I was just hoping someone could point me to a similar (if not exactly the same) example.

Oh well, I could be wrong and it may not be possible.

Reply with quote

martin
Site Admin
martin avatar
Joined:
Posts:
40,476
Location:
Prague, Czechia

Philip wrote:

I wouldn't be surprised if there's a way to do this with existing functionality. I think it's just a matter of passing parameters back and forth among WinSCP, SVN, and the shell (in my case Windows batch files). I was just hoping someone could point me to a similar (if not exactly the same) example.
You can use local custom command for the first part of the task (download file locally and to the check in). But WinSCP wont't upload the file back. See documentation.

Reply with quote

Advertisement

kovacsbv
Guest

How about just using Tortoise SVN from tigris.org?

Tortoise manages local copies of SVN code and updates, checkouts, etc from your windows machine. It supports svn+ssh (which is what I think you want). Is there a reason you need to use WinSCP for this?

Reply with quote

Advertisement

You can post new topics in this forum