Archive for March, 2008

High Leverage Development

Wednesday, March 26th, 2008

During our third month of porting SftpDrive to OS X, it became clear that creating and maintaining a cross-platform codebase of high performance network and filesystem code would be far more effort than we had hoped. It wasn’t that the project was impossible, or even absurdly difficult. It just wasn’t any fun. Every time I looked at a #ifdef WIN32, it was even more clear the code was becoming much more tedious to debug and maintain.

It seems our work on Slingshot spoiled us. A few months working with Ruby, Objective-C and C# left us feeling happy and optimistic about programming—anything was possible! Needless to say, the tens of thousands of lines of procedural C in SftpDrive for Mac no longer brought about the same feeling of joy. It seemed unfair that hot-shot-web-developers, with their pretty MacBooks, got all the attention, and they got to use fun high-level languages like Ruby or Python. We were developing a truly useful piece of technology, but were stuck on Windows and spending more than 50% of our time dealing with “pedestrian” details like pointers, memory management, IRQLs, and IRPs.

Still, we fancied ourselves hardcore and kept at it even though it was hard (and sometimes boring). When it was time to write an auto updater for SftpDrive we spent hours upon hours searching on Google and MSDN trying to find a clean implementation that would work on a vanilla Windows 2000 installation. One option, WinInet was ridiculously ugly and verbose. Another option, WinHTTP, didn’t work on Windows 2000 GM. We ended up using libCURL. It was a ridiculous and frustrating waste of time.

We wanted to ‘import httplib’, and then just start making things happen. XKCD hits the nail on the head:

XKCD python

We couldn’t afford to keep spending time and energy writing software this way. Even if we could afford it, we didn’t want to spend our time this way. Web applications were being developed at an astounding pace in part because of centralized management and deployment (they never have to maintain different versions for Macs and PCs), but also because they were using modern interpreted languages. Web developers also used community-developed open-source projects when they needed some help on a routine problem. They didn’t have to reinvent the wheel at every turn, but instead focused on the core of their product. With high-level languages and good libraries, small teams can create great products at a rapid pace. We realized that we could write applications for the desktop in the exact same way.

We rewrote SftpDrive from top to bottom in Python, with a GUI in Objective-C. It’s called ExpanDrive, and it took 1/3rd the time that SftpDrive took to develop. We greatly leverage Python and and many open source projects—just like a web-developer. To minimize conflicts and to have the necessary control over the runtime environment, our build process extracts only the necessary bits from the full python distribution and packages it into the .app. We trim Python from 5000+ files to a few more than 400. Like many OS X apps, we use Sparkle.Framework to automatically distribute and install updates. We’re pushing out weekly updates which include more than just bug fixes. ExpanDrive has been a breeze to maintain and extend and the core remains perfectly cross platform.

Desktop applications aren’t dead, they’re just about to really get going.

ExpanDrive 1.04 released

Thursday, March 20th, 2008

ExpanDrive 1.04 is available for download and is also available on the the auto-updater. It includes a variety of fixes and small refinements, all listed in the release notes. The user interface continues to be refined - we now have a multi-pane preferences dialog that includes some new options users have been requesting such as the ability to disable display of the drive manager when launched.

You can disable display of the ExpanDrive manager at program launch as well as display the recent drives menu in line or as a sub menu.

in line

as a submenu

On the filesystem end, our meta-data cache is now even more powerful. Acess to large projects in applications such as TextMate is sped up dramatically. Symbolic links that point to relative paths are now correctly interpreted. A variety of smaller improvements and bug fixes have also been made.

ExpanDrive for OS X

Tuesday, March 11th, 2008

Magnetk is thrilled to announce the release of ExpanDrive for OS X, our second product. We’ve been working for a long time on ExpanDrive, and are very proud of the result. Our early adopters seem quite pleased too.

ExpanDrive builds SFTP support right into the core of OS X - just like SftpDrive builds SFTP support into Windows. Now any application on your Mac can read and write remote files as easily as if they were on a USB drive plugged into your computer. ExpanDrive even brings SFTP right into Finder, letting you manage your remote server as easily as your MacBook. We’ve already pushed two updates in response to user feedback in just the first week of open release, polishing the UI and improving user experiences all around. In the coming weeks and months ExpanDrive will expand beyond just SFTP, letting you access a wide variety of data through the filesystem. Keep an eye on this blog, as well as our Twitter feed, to keep track of the developments.