Archive for August 2006

TextMate and Vim

I’m probably switching back to Vim. Not for everything, mind you, but I’ve found that my fingers miss the speed of Vim’s keystrokes. Perhaps it’s possible to be as fast in TextMate, but it’s been a while now and I still feel like I’m slugging through quicksand. And yet TextMate is pretty darn cool, and I like it a lot. I suspect I’ll go back and forth. There’s nothing quite like the buzz I get from whipping through code at the speed of light in Vim. ;)

Where does Vim fall short? My experience has been that it didn’t used to integrate well with other Mac apps (clipboard stuff), and Unicode support wasn’t all that great. It seems to work fine with the clipboard, and apparently Unicode is up to par as well (but I haven’t tested it yet). My bet is that some of the small frustrations I ran into with Vim back a few months ago were all configurable — meaning, I could’ve gotten what I wanted by changing the configuration.

Not that I can see the future, of course :), but I think I’ll probably end up using Vim for everything except perhaps Rails coding and stuff involving Unicode. We’ll see…

Mephisto on Bluehost

Stumbled across Mephisto today. It’s a Rails-based blogging system, and dang does it look good. ~drool~ I am pleased with WordPress, mind you, and it’s treated me well, but I’d really really really love to blog on a Rails blogging app so I could tweak things in Ruby instead of PHP. I like what little I’ve seen of Mephisto, too.

I’m not sure if I’ll be able to install it on my servers, though, because you have to be running Edge Rails (revision 4727), and Bluehost has 1.1.6. Nor do I think they’d upgrade their servers just for me. :) Beyond that, it helps if you can install gems, but I can’t. Time to post to the forums

The other thing is that this is a project I can actually see myself contributing to. WordPress could have got a few lines of PHP out of me, but coding Ruby for Mephisto would be quite fun. If I can get it installed, the first thing I’m going to write is a WordPress-to-Mephisto converter so I can move all my blogs over.

(cons calculus (cdr ‘(eating is fun)))

Last night I spent an hour or so working through Calculus and Pizza: A Cookbook for the Hungry Mind. While I don’t care so much for all the pizza/food stuff (extra fluff that gets in the way of what I’m after), the math is good. I’ve relearned how to do derivatives, find local minima and maxima, use the chain rule and extended power rule, and so on. Still haven’t gotten to integrals yet, though. The calculus is pretty easy, I must admit; the only thing that keeps hanging me up is the algebra. Most of the algebra is a piece of cake, of course, but there are little bits and pieces here and there that I keep forgetting. But it’s coming back.

After that, I picked up The Little Schemer and spent a most enjoyable two hours working through the first 80 pages. At first I didn’t intend to actually write all of the little functions you’re expected to write, but I’m glad I did. And to my small surprise, I was able to write all of them without too much trouble. We’re talking functions like +, -, >, and < , folks. Simple stuff. It’s like writing the language from scratch yourself. (Yes, I know there’s more truth to that than there may seem at first. :))

The coolest thing is learning how to solve problems recursively rather than iteratively. Sure, some of this stuff would be far easier using a for loop, but using recursion like this means no side effects (at least if I understand correctly), and that’s sweet. I can’t wait to finish the rest of the book and move on to The Seasoned Schemer. (And I’ll be glad when we move on to higher-level programs, too.)

Oh, the parentheses in Scheme don’t bother me at all — in fact, I rather like them. :)

A postscript

I’m going to learn to code PostScript. It’s something I’ve been meaning to do for a while, and then today I found this page, which has links to Thinking in PostScript, the Red Book, the Blue Book, and the Green Book, so I certainly have enough reading material to keep me occupied. :)

Why? Well, first of all, it’s not a common programming language. It’s also used quite often in printing and typography, and that’s right up my alley. I have a few ideas for programs where I’d like to be able to generate an EPS which I can then import into the books I design, for example (genealogy charts and such). And it sounds cool. :)

Proofs and stuff

I read Stevey’s Math Every Day post, and darn it all, I need to start brushing up on my math! It’s been ages since I studied it (five years, to be precise), and while a fair amount is still with me (like addition and subtraction ;)), it’d be nice to re-master everything I once knew. And then I’ll be able to start learning all the really cool stuff in math. Mmm.

Problem is, I’m not quite sure how to go about doing it. Pick up a textbook and work through the problems, one by one? Find some other kind of math book? Wikipedia? MathWorld? I don’t know. I’m not even exactly sure what order I should study things in. I do know that calculus was last, though. :)

I think I’m going to do what Stevey did — “math every day.” Ten minutes a day will be good for starters, and on days when I have the time, I’ll be able to do more. Mmm, I miss math.

All zipped up

Some of our projects at work have been using ActiveXZip, a free zip compression library. The only problem is, it apparently doesn’t work with ASP.NET 2.0 (we upgraded recently). Nor do I particularly care for the annoying splash screen that comes up whenever you initialize it.

My co-worker found SharpZipLib, which showed a lot of promise. I downloaded it and tried porting our existing code over to use it, but I’m running into some trouble using it to create a zip file. The sample code is…well, look at it this way — it takes 40 lines of code to add a file to the zipped archive. Forty! In ActiveXZip, it’s one. That’s how it should be. A zip library ought to take care of all the nitty-gritty technical details and let me worry about my app instead.

I wish I were coding in Ruby or Python… ~sigh~

In the meantime, today I discovered Stevey’s old blog (and his new one) and will be reading through the archives.

A touch of the hand

Seeing Jeff Han’s multi-touch demonstration over at TED (and I’d seen a similar demonstration before, on Jeff’s website) made me drool with goosebumpy excitement. (There’s a bunch of other cool stuff on his site, too, like the LED touch display and the Media Mirror.) Innovation is soooo cool. :)

So now it’s just a matter of time before these multi-touch devices go mainstream. Mmm…

More Rails love

Lately, the need to finish these major projects at work before I switch jobs at the end of August has turned most of my coding time (well, all of it right now) into ASP.NET time. Blech. It’s okay, I suppose, and it could be worse (COBOL, anyone?), but I miss Ruby on Rails. Soon, Ben, soon. :)

In the meantime, the library finally got me Agile Web Development with Rails via ILL. I’ve been waiting a while for it. :) Just reading about Rails makes me happy. (Speaking of which, I must be behind on my Rails blog reading. Maybe I’ll do that for a while today… :))

Another little project I’ll do sometime soon is convert my Perl etext script into Ruby (it takes Project Gutenberg texts and preps them for InDesign by removing extra blank lines, removing newlines, replacing two hyphens with an em-dash, etc.). It can’t be that hard — it’s 15 lines long :) — and it’d be a nice back-to-Ruby project to tide me over until all this work stuff is finished.

Speaking of which, I really, really, really wish I could write this extraction web app in Rails instead of ASP.NET. I could get it done sooooo much faster, and I’d be happier. But the rest of the site is in ASP.NET and I’d have to get the sysadmins to install Rails on the server and it’d probably be too much trouble. ~sigh~ Oh well — only one more month of it, and then it’s goodbye forever to .NET. Period. :)