I've just installed vcscommand.vim, which integrates version control into vim. I was trying it out and was getting the error "No suitable plugin" whenever I ran a command. Turns out this was because I wasn't actually in a working directory, I was in the directory I initially imported. So, remove the directory and then checkout the source, now all good.

When working with Ruby's Find, don't change directories with FileUtils.cd, as Find gets confused. You're better off working with full paths (use File.expand_path).
I'm a two-bit hacker. Most code I've written to date is small and self contained, rarely more than a couple of files. For that reason, I always thought that version control was a bit overkill--a good idea, but not really worth the effort on small projects. However, at work we do use version control and it's been an interesting experience. The main selling point for version control software is the ability to track changes, but I've found that the changes that using version control software has made to my coding practice have been the most useful. Instead of hacking away ...
[read more]
If you want to pass information to a Camping controller, all you have to do is define the class like this: class Index < R '/(\d+)' get(id) Now whatever was matched by the regex \d+ can be retrieved by the variable id. If you want to pass more than one variable, just chain them like this: class Index < R '/(\d+)/(\w+)' get(id, action) Each of your regex groups will be passed as a variable. If you forget to add the arguments to the get method, you'll get an error like this:

Camping Problem!

MyApp::Controllers::Index.GET

ArgumentError wrong number of arguments ...

[read more]
I have GNU screen running on a couple of boxes. Occasionally I accidentally ssh from inside screen to the other box and attach the remote screen, purely out of habit. That means that C-a sends a signal to the outer screen. You can send a real C-a to any application through screen with C-a a, so to detach the inner screen you use C-a a DD.
One of the most raved about features of TextMate is snippet expansion. Felix Ingram has written a Vim plugin that emulates this behaviour, SnippetEmu. I haven't had much of a play with it yet, but it looks like a real time saver. You need Vim 7, and make sure you have the following in your vimrc: filetype on filetype plugin on
I've just created my first Yahoo! Pipe, and it was incredibly easy. I subscribe to Lifehacker, which is full of really good ways to procrastinate - ah, improve your productivity. However, I use a Mac, so I really don't want to see all the Windows tips. The screenshot below shows what 30 seconds in Yahoo! Pipes let me do; filter out all the Windows tips. Lifehacker feed in Yahoo! Pipes Here's the feed.
I'm trying to build PHP against the MySQL supplied binary on my Mac mini running 10.4.9. For some reason it's looking in the wrong place for libraries, so I get the following error: /usr/local/mysql/lib/mysql/libmysqlclient.15.dylib Referenced from: /Users/michael/build/php-5.2.3/sapi/cli/php Reason: image not found /usr/local/mysql/lib exists and contains the libraries. It seems like a horrible fix but the following "fixes" the problem: sudo ln -s /usr/local/mysql/lib /usr/local/mysql/lib/mysql
When you save an object to a session in one file, say write.php, and then retrieve it from another, say read.php, PHP needs to know about the class definition so that it knows how to unserialize it from the session. If you don't include the class in read.php, you'll get an error complaining about __PHP_Incomplete_Class.
In the middle of the Tomcat 5 installation, MacPorts was unable to download the required version of antlr, 2.7.7. After a bit of digging, it became clear that this was because the antlr website only has the latest versions available for download. The required version of antlr is available in the gentoo distribution, so you can get around the problem.
  1. Download antlr-2.7.7.tar.gz from gentoo or I mirror. I got it from Planet Mirror.
  2. Edit the antlr portfile (by default it's at /opt/local/var/db/dports/sources/ rsync.rsync.darwinports.org_dpupdate_dports/lang/antlr/Portfile (line split for readability)). You need to change master_sites to the location of the antlr ...
[read more]