is idefrag really worth the money? 15. Nov 2010
Since the performance of my Snow Leopard system was rather lousy and I decided it might be worth a try doing a defrag of my hard disk. Of course what they’ve always been telling you is, that Mac OS X is a smart operating system that does defragmentation on the fly and thus doesn’t need to be defragged by a dedicated program. They even told you, that it’ll most likely decrease system performance. I ignored all advice and decided to buy iDefrag to see what reality looked like. I decided further I’d do some highly unscientific benchmarks to see if any significant improvement was achieved.
The full defragmentation of my 320 GB hard disk took 18 hours. This means it didn’t finish overnight and I had some time off from my computer which resulted in buying a dead tree newspaper, finally hooking up my old school radio to the wall socket and some overdue house work getting done. I actually quite enjoyed having a day without computer usage for the first time in a very long time and decided to try to make this a habit.
I don’t reboot my system very often. Mostly when installing security updates or occasionally when installing software which requires a reboot to finish the installation. Nonetheless long startup times are rather unpleasant. So what effect did the defragmentation have on startup time? Disillusioningly little.

The effect was clearly measurable but not significant enough to make me have feelings of joy. So, what about launching applications and going to sleep?

So here we have mixed results. Little to no improvement for Lightroom, Photoshop and Firefox, but a very pleasing improvement for Itunes and a fantastical improvement for switching to sleep mode. I can only speculate where the improvement of the Itunes launch time comes from, but the improvement of going to sleep seems quite reasonable considering that prior to the defragmentation /private/var/vm/sleepimage consisted of more than five thousand fragments being one of the most highly fragmented files. If this would have been the only fragmented file I guess I could have just deleted it and it would have been recreated, but since the whole drive was rather fragmented It probably wouldn’t have had the same effect. All in all I don’t feel ripped off, but neither am I specifically satisfied with the results, but I guess this doesn’t really matter anymore as soon as solid state disks become affordable.
delete all instapaper items 23. Oct 2010
Of course you could simply delete your account and recreate it, but that wouldn’t be as much fun as playing around with curl.
curl --cookie-jar cookies.txt --data "username=foo&password=bar" \
http://www.instapaper.com/user/login
curl --cookie cookies.txt http://www.instapaper.com/u |\
sed -E -n "s/.+\/delete\/([[:digit:]]+).+/\1/p" |\
xargs -I {} curl --cookie cookies.txt \
http://www.instapaper.com/delete/{}
install lift with scala 2.8, sbt & jrebel 30. Aug 2010
Here’s how to get Lift running with Scala 2.8, SBT and JRebel on Mac OS X:
1) Download and install the JRebel nightly
$ wget --referer \
http://www.zeroturnaround.com/jrebel/next-releases/ \
http://www.zeroturnaround.com/downloads/jrebel-nightly-nosetup.zip
$ sudo unzip -d /usr/share/java jrebel-nightly-nosetup.zip
$ cd /usr/share/java
$ export JREBEL=jrebel-nightly-`date "+%Y-%m-%d"`
$ sudo mv jrebel $JREBEL
$ sudo ln -s $JREBEL/jrebel.jar jrebel.jar
2) Request a JRebel Scala license and copy it to the JRebel directory
$ sudo cp javarebel.lic /usr/share/java/$JREBEL
3) Install the Simple Build Tool via MacPorts.
$ sudo port install sbt
4) Edit the SBT launcher script (at /opt/local/bin/sbt)
JREBELJAR="/usr/share/java/jrebel.jar"
JAVA_OPTS="-Xmx512M -noverify"
exec java $JAVA_OPTS -javaagent:"$JREBELJAR" \
-jar "$LAUNCHJAR" $QUOTED_ARGS
5) Clone the SBT prototype of Lift to your development directory
$ git clone http://github.com/lift/lift_21_sbt.git
6) Comment in the following line in project/build/LiftProject.scala
override def scanDirectories = Nil
7) Change to the project root directory and start SBT with automatic redeployment
$ sbt
> update
> jetty-run
> ~ prepare-webapp
8) Open http://localhost:8080/ in your favorite browser
9) Make a change to src/main/webapp/index.html and refresh your browser
10) Enjoy productivity!
search multiple domains on google 28. Aug 2010
If you want to restrict your google search to a domain you can use the site syntax:
site:blogspot.com
This is really useful and I actually use it quite often. But wouldn’t it be nice to able to restrict the search to multiple domains? No problem, just use the following syntax:
site:blogspot.com | site:wordpress.com | site:typepad.com
Alternatively you can use this syntax:
site:blogspot.com OR site:wordpress.com OR site:typepad.com
The OR must be capitalized for the query to work. Sometimes it may happen that the number of search results displayed below the search field actually decreases after you have added an additional domain. I’m not sure if this means that the actual number of search results is smaller or if it is just a statistical error.
disable smart location bar in safari 28. Aug 2010
If you’re also annoyed as hell by the new address bar autocomplete feature in Safari that searches not only URLs but also titles then rejoice because SMRT is here to save your sanity. Suddenly Safari is usable again and you can finally upgrade and take part in all the extension fun!