Using RSync with Projects

Posted by shanec on 2007-01-26 13:47
Question: 

How do I publish file in my local project to a remote system?

Answer: 

One of the questions that has come up a few times through the development of Komodo 4.0, is "Why don't we have project publish features?" Well, to be honest, it was one of the features that got left behind for the time being. But there is a good way to add publishing capabilities on your own, and I'll show how in this article.

The simplest way to do this is with rsync. "rsync is an open source utility that provides fast incremental file transfer." It can synchronize files in a directory between two machines. For security, rsync can be combined with the use of ssh.

Attached is a project template that allows you to create new projects that support RSync over SSH. There are two simple commands to upload and download. I'm sure more could be added.

You can import the project into the toolbox to look at it, but preferably drop it into your project templates directory.

OSX:
~/Library/Application Support/Komodo/4.0/project-templates/My Templates/rsync.kpz

Linux:
~/.komodo/4.0/project-templates/My Templates/rsync.kpz

Windows:
%APPDATA%/ActiveState/Komodo/4.0/project-templates/My Templates/rsync.kpz

Some software you may need

* rsync: http://samba.anu.edu.au/rsync/
* ssh: http://www.openssh.com

OSX:
* ssh key agents (only one of the following)
- http://www.sshkeychain.org/
- http://www.phil.uu.nl/~xges/ssh/
- http://www.versiontracker.com/dyn/moreinfo/macosx/13221

Windows:
- http://www.chiark.greenend.org.uk/~sgtatham/putty/

AttachmentSize
rsync-project.kpz5.97 KB

aks | Mon, 2009-02-09 14:10

How do I modify this template to support using the '-e' option with rsync, as in:

rsync -e 'ssh sshproxyhost ssh' from-files user@host:/dest/path/to-files

Thanks

shanec | Mon, 2009-02-09 14:36

You can open the template as a project and make the appropriate changes to the run commands, then "save as template" to create a new project template.

iamnoskcaj | Sun, 2009-12-06 14:27

I was pleased to discover this template, but ran into a problem with it today.

Hopefully someone can help me with this...

I created a new project, provided all the configuration values it asked for in the wizard... and used the option to download the site remotely first.

It grabbed the files in the root directory, but nothing in the subdirectories off the remote server.

Has anyone seen this before?