Sunday, July 31, 2011

sls (combination of ssh and ls)

Here's a little bash script I just wrote and thought somebody might find useful. I'm always moving files around using scp and also needing to ssh around to ls them. So why not combine the ssh and the ls into sls -- just like scp, right?

Here are the usage and help text...

usage: sls [ls-option]... user@host[:file]...

sls is a magical combination of ssh and ls. Simply give the sls command some (or no) ls options and one or more remote locations and you'll get a listing for each. The remote spec is the same user@host:file specification you would use with the scp command, and the file part is optional.

And here is the script itself. If you have any fixes or improvements, please let me know.

p.s. Blogger, when I write a post in HTML, please let me edit it the same way... thank you. And to visitors from the future, if you find yourself needing to edit your HTML-written post, it's actually easy now that I think about it. Just ask your browser to show you the source, grab what you need, and paste that back into the post editor.

Thursday, July 28, 2011

Deploying GWT

I'm ready to try deploying my GWT app to WLS... so how u do dat?

I found a handy how-to on

Thanks, Erik!

Tuesday, July 26, 2011

GWT widgets with radio buttons

Here's something I learned today.

First the problem, which was that setValue didn't seem to be doing anything -- my radioButton's weren't getting set. This isn't actually true. It turns out that if I scrolled down, one of the radio buttons on the page WAS getting set. Can you guess what was going on? That's right, all of the radio buttons from all sets all had the same name.

Heres the lesson: If you make a GWT widget that has radio buttons in it, and you use more than one of these widgets on a single page, you're going to need to make the name of each radio set unique.

And my solution: What I did was to use the hashCode of the panel that contains the buttons, and this worked just fine.

You're welcome!

Sunday, July 24, 2011

Summer nest boxes

This is mainly a note-to-self about how to make summer nest boxes, the kind that are open on top. I'm always forgetting the dimensions.

Cut from a 1"x10"...

- a 4" piece for the front
- a 7" piece for the back
- a 17.5" piece for the bottom
- two 17.5" pieces for the sides

The front and back stand on top of the bottom, such that the interior length of the box is 16".

The sides and bottom rest on the same surface, such that the exterior width of the box is 10.75".

If you cut the 17.5's short by the width of your saw blade, you should be able to get three nest boxes out of two 8-foot boards -- one board for five 17.5's and two 4's and the other board for four 17.5's, one 4, and three 7's.

Which nails to use? I'll be back to answer this all-important question.

Saturday, July 09, 2011


That's a lot of punctuation.

But here I am!!

Friday, July 01, 2011

Fun with Eclipse on Mac OS: the command/option saga

When I tried to run Eclipse on my Macbook Pro the other day, I discovered that the command and option keys were reversed. If I tried to Paste with cmd-V, I'd get some funny character, but if I typed opt-V, it would paste. Instead of quitting, cmd-Q would insert this "œ" character, which is supposed to be input via opt-Q, which instead would quit me from Eclipse. Yeah, loads of fun.

I googled all around and found nothing, nothing at all, about this. The only other thing I could think of was to submit a bug (this one) and hope that someone could point me to some page about a gotcha... or whatever.

Well the plot thickens. Turns out that if I create a new user account on the Mac, that user doesn't have the same problem. So at least I know it's not even something about my system, but rather about my normal user account. So if I can't figure out, the worst case solution is I have to switch users to run Eclipse. Maybe I'd just switch to a new user account instead and move all my stuff to it.

But before I do all that, I'll see if I can figure out what it is about my account that's causing this. If I find any answers, I'll be posting them here.

Update: I tried a bunch of things -- moving all of the Preferences out of ~/Library, moving .* out of ~, moving Application Support files... I finally got fed up and just created a new account. Oh what fun this will be! :/