Thursday, February 5, 2009

Finding Synergy Between Emacs and SFTP

I needed a solution to edit files over SFTP connection. In Linux I could have just used SSHFS on top of FUSE, but I was stuck in Windows.


I was suggested to use proprietary software called SftpDrive. And not just proprietary, but a shareware with trial period of six weeks. I agreed, thinking, that I won't be needing it for any longer.

But the program didn't fulfill my expectations. It failed to cooperate with my text editor, making Emacs complain all the time that the file I'm editing has been changed on disk. The reason seemed to be, that changes to the file attributes (particularly the modification time) aren't immediately available to emacs after saving the file (as explained in this Q&A site).


From the same site I found a suggestion to use Dokan SSHFS instead. It appears that Dokan is a library similar to FUSE in linux. And Dokan SSHFS similarly sits on top of that.

At first I got a bit puzzled over the Licensing of Dokan, because although Dokan project page in Google Code says it's licensed under LGPL, the installer displayed me the following message:

WARNING: This computer program is protected by copyright law and international treaties. Unauthorized duplication or distribution of this program, or any portion of it, may result in severe civil or criminal penalties, and will be prosecuted to the maximum extent possible under the law.

Later I found out that this installer message had been automatically generated by Microsoft Visual Studio. How nice of Microsoft to have a happy little default licensing scheme.

Dokan SSHFS isn't as easy to install as SftpDrive – I had to download and install three different software packages to make it work. But it is free software. And it seems to do everything SftpDrive does. Plus achieving synergy with my Emacs.

Windows likes proprietary

I'm starting to wonder, why the proprietary alternative had been suggested to me at the first place?

But then... How could I have expected a free software suggestion from a Windows user?

No comments:

Post a Comment