Jack That Shat!

So you just wooted some awesome new desktop speakers for your Ubuntu desktop computer, you plug them into the headphone jack, and you behold the megawatt goodness of thumping 4-inch speakers. But what ho? What’s this? The on-board sound card speaker is still pumping it’s pathetic little pings and bleeps into your otherwise blissful aural wonderland! It’s enough to drive a command line idiot to drink. Well, pretty much anything is enough to drive this command line idiot to drink. Things like “Mother’s Day” and “Tuesday”.

You would think that plugging something into the headphone jack would automatically shut off the speaker inside your box. You’d think that, but you’d be wrong. Not only are you wrong, but it’s such a stupid thing to want that the Ubuntu gods have hidden the setting under like 500 menu levels. Let’s go digging, shall we?

In the upper right corner, you have a volume icon. Click on that, and select “Volume Control”.

In the “Volume Control” dialog, you’ll see all of the volume sliders for various outputs. Select “Preferences”.

Now, you can control which settings show up in the “Volume Control” dialog. About halfway down the list, you’ll find the setting for “Headphone Jack Sense”. Yes, let’s please jack some sense into these headphone outputs, shall we? Check the box.

Now, back in the “Volume Control” dialog, you’ll find a new tab for switches. Our preference for headphone jack behavior shows up there.

That’s it! Now, you perfectly idiotic request to shut down the internal speakers when you plug in headphones (just like every other operating system does) will work with your fancy new speakers.

Now leave me alone. It’s 10am, and this tear-soaked gin & tonic isn’t going to guzzle itself.

I Spy, With My Little Bmon

So, it’s been a little while. Rehab was great, then I did a little walk through the Colorado Mountains that lasted 9 months, now I’m back and more command line idiotic than ever I was.

I built a little rsync script that uploads all of the audio from my recording studio hard drive to a backup drive on my home network. Why? Because mozy.com has a stupidly slow upload limit, and carbonite won’t allow you to backup external drives. So, rsync, cron, a home network and $100 hard drive from costco to the rescue. I’ll give a detailed outline of how I built the system later, but for now, just a little tool to alert you to.

The rsync job, when it runs, takes forever, and chews up a ton of bandwidth on the home network. I wanted a quick way of logging in remotely and seeing, in realtime, how much bandwidth was being used by the home server (a Linux Mint mediabox, mostly). My initial plan was to call my wife at home, have her fire up the monitor and read the numbers to me, but that only works twice, then she stops taking my calls.

Bmon to the rescue.

sudo apt-get install bmon

It’s simple, it’s quick, it works, it has fancy (ascii) graphics if you want them, and it tells you at a glance just how much of your network pipe is being sucked down by a silly little backup script from a remote studio computer.

Stack That Shat!

Nathan Ford over at Unit Interactive wrote a great post about making better use of the CSS font-family stacks, to recover the use of fonts that many designers had neglected. The post is here:

Better CSS Font Stacks

I instantly became a true believer, like the bright-eyed stepchild of a country preacher at church camp. Hallelujah! My own small contribution to this effort is simply to take Nathan’s work and put it into an actual *ahem* CSS file. So, grab it while it’s hot:



12 Signs That The Recession Has Hit The Internet

The United States economy is in a funk. Food prices are up, oil is through the roof, real estate has collapsed, and credit is becoming scarce. Here are 12 signs to look for when the recession hits the Internet:

  1. Digg.com moves their server over to Dreamhost
  2. Jeff Bezos delivers his TED talk with a GoldenPalace.com tattoo across his naked chest
  3. i can affordz cheezburger?
  4. Drew Curtis switches to Pabst Blue Ribbon
  5. For $20, Rick Astley will show up to do it in person.
  6. Woot.com starts accepting payment in Flooz
  7. Jeph Jacques sells all remaining ad space to Warner Music Group
  8. Nigerian spammer steals your identity, only to return it 3 days later when he finds out your credit score
  9. Scoble spruces up resume for sweet new gig as Hugh MacLeod’s intern
  10. StuffWhitePeopleLike? Liquidity.
  11. Guy Kawasaki trades in his MacBook for a Dell
  12. You hire a PHP Developer for $12 an hour through elance.com, and it turns out to be Matt Mullenweg

Up the WP

Give me WordPress, give me WordPress
You can have all the rest, give me WordPress

I love Matt’s little blogging engine that could. It’s easy, fast, and pretty to look at. It’s easy to install. It is not, however, fun to upgrade.

That’s a problem, because people keep on coming up with tricksy little ways to burninate WordPress. Now, the folks who write the code are pretty good at staying on top of chinks in the armor, but that means that every time they say “update”, I have to update. Being the lazy ass that I am, I don’t like to keep doing things the hard way, ftp’ing data up and down, so I wrote a little bash script to do the badness for me. Now, I can go from vulnerable to updated in 0.4 seconds flat!

Let me take just a second to give mad props to the WordPress folks for a simple decision they made early on, that makes a world of difference to guys like me: you will always, always find the latest version of WordPress at the same location:


Simple, easy, but by avoiding all the complications of version numbering and folder locations in the download URL, they make it possible to write scripts like this. Thanks, guys!

If you don’t know how to use bash scripts, check out this tutorial: Bash it! Bop it! Script it!. It’ll show you where to put the script, how to make it executable, and how to call it from the command line. The script itself is in the download link below, and it’s pretty well documented, so you should be able to figure out why everything is there. Here’s a stripped down version, with none of the documentation:

#! /bin/bash
# =======================
# WordPress Upgrade Script 0.1
# Written by Command Line Idiot
# http://commandlineidiot.com
# You may use, modify, and redistribute this script freely
# Released: April 2008
# =======================
echo 'WordPress server location, without trailing slash (ex. /var/www/mysite.com/blog)'
read WPLOC
rm -rf $WPNEW/wordpress
rm -f latest.zip
wget http://wordpress.org/latest.zip
unzip -o latest.zip
rm wordpress.zip
rm -rf $WPLOC.bak
cp -rv $WPLOC $WPLOC.bak
cp -rfv $WPNEW/wordpress/*.php $WPLOC/
cp -rfv $WPNEW/wordpress/wp-admin/* $WPLOC/wp-admin/
cp -rfv $WPNEW/wordpress/wp-includes/* $WPLOC/wp-includes/

You can download the script here:

WordPress Update Script 0.1

Share and enjoy!