(Mega) Mall Rat

January 2nd, 2009

It was cold and bleak in Minnesota. What to do with two small children, extended family visiting from disparate points, and temperatures hovering around -10 Fahrenheit?

Mall Of America, of course!

I will admit to spending not one, not two, but three full days at the mall. I walked all three levels in both directions. The perimeter is approximately 6/10 of a mile, so I managed to get a minor (if culturally and hypsometrically flat) “hike” in during my visits. 

Fun and wet: riding the log chute in the amusement park. Fun and pricey: full-motion WWII dogfighting against my brother.

I have my limits, though. I will probably not want to set foot in another mall until, say, Christmas 2012. Mayans, beware.

Outdenting Code In Emacs On OSX

December 23rd, 2008

When flirting with TextMate, I got used to using normal-person keyboard shortcuts for indenting (⌘-]) and outdenting (⌘-[) blocks of code.

Emacs scoffs at normal people.

In emacs, every language mode has its own peculiar notion of indentation. To make it possible to bind keys to indentation functions, indent-according-to-mode was introduced. This function looks for a buffer-local variable called indent-line-function and invokes it if found. Major mode authors know to point indent-line-function to their mode-specific indentation code.

At first blush, whoever built this mechanism appears to have neglected the equally important “outdent” feature. It’s not a surprise, though. Historically, in the world of emacs, mode-specific indent has been closer to “format this code nicely” than to “insert spaces or tabs.” Of course, we now have popular whitespace-dependent languages (Python) and markups (YAML) for which code formatting is less useful.

Read the rest of this entry »

ExpanDrive Is Nifty

December 18th, 2008

Like most developers who do web stuff, I sometimes need to edit files on a remote server. It turns out that this is a pain in the patookus. Or, at least, it was.

After the thirty day trial, I gave in to the power of ExpanDrive. Those thirty days convinced me that $40 was well worth the price of admission. It’s nifty to be able to mount your remote filesystems via SSH as if they were just network disks.

And yes, before I spent my bucks, I carefully evaluated using emacs tramp-mode, remote emacs via terminal, CyberDuck, Transmit, MacFuse with SSHFS, and MacFusion. I even looked at improving my source control policies and using Capistrano (yuck!) or Fabric (too immature!)

ExpanDrive is based on MacFuse, but not SSHFS; this makes all the difference. Whatever caching magic they do makes ExpanDrive scream when working with lots of small files in nested directories. Perhaps the SSHFS folks will catch up sometime soon, but at the moment the distance between the two is vast enough to justify the cost.

And I can’t wait for ExpanDrive’s planned S3 disk feature. Hot!