quickies

Distributed Drupal development, determined by dedicated Drupaler

jp.stacey 20 August 2007

A recent thread on the Drupal development list (started by me, I confess) led to Larry Garfield publishing his development environment online.

Image submit buttons in Drupal FAPI

jp.stacey 20 August 2007

Drupal 5.x's FAPI doesn't handle image buttons terribly well: here's how to implement it with the #button_type property. And a minor refinement that Victoria and I implemented today at work.

Visualizing an application's entire call stack

jp.stacey 5 September 2007

KentBye, Flickr user, has been playing with GraphViz. He’s used it to turn an XDebug output into a pretty visualization of Drupal’s call stack, or what functions call what functions during a typical Drupal request.

Want somewhere to stay in Brittany?

jp.stacey 13 September 2007

My parents-in-law own a cottage in a place in France called Pont Camarel. They asked me to build them a site. I did. That’s it.

Checking the changes for many svn versions, one version at a time

jp.stacey 30 October 2007

Say you want to see both the log and diff of a given svn version, just the differences between it and the previous version, plus log message (i.e. what was committed, and why, for version NUM) The following will work at a bash command prompt:

$ r=NUM; rr=-r`expr $r - 1`:$r; svn log -r$r; svn diff $rr

It looks a bit unwieldy, but you can keep pressing the up arrow and home key, and re-editing NUM, multiple times to look at multiple changes:

Insert any Javascript bookmarklet

jp.stacey 10 December 2007

As the natural extension of Gareth Rushgrove’s bookmarklets for inserting the Dojo or YUI Javascript toolkits mentioned by Simon, here’s a tidying-up of a bookmarklet I’ve been using to bring in any Javascript using user input via a popup prompt:

Insert-JS bookmarklet

SQL Server error: sqlboot.dll

jp.stacey 17 December 2007

After several administrative steps over a few months, we suddenly found the following error coming from an instance of SQL Server on a virtual machine:

Your SQL Server installation is either corrupt or has been tampered with (unable to load SQLBOOT.DLL). Please uninstall them re-run setup to correct this problem.

Subversion log messages need not be set in stone

jp.stacey 14 January 2008

Simon Willison mentioned a while back a link to help on how to undo a svn commit in subversion (more a kind of internal branching than an actual undo, of course: but that’s subversion). That’s all very well, but how about undoing the log message for a particular commit?

How to see Last.fm from the other side of the room with LastJS

jp.stacey 2 March 2008
Proof of concept, more than anything else: how to hook up to a recalcitrant Flash-based interface.

Back from a rather physical near-week of team building with work, I’ve been listening to Last.fm today to recuperate and nurse my tired muscles. But with the music playing on our crusty, trusty old purple iMac in one corner, and me in the other reading, drinking tea or otherwise recuperating, how can I tell at a glance what the current artist is?

With apologies to Hanlon

jp.stacey 7 April 2008

“Never attribute to malware that which can be adequately explained by stupidware.”