17 July 2007

Too cool for screenshots?

Mac OS X comes with a command-line utility, pbcopy, that copies its stdin to the clipboard. pbpaste dumps the clipboard to stdout.

13 July 2007

Usability gripes

I wonder if I'm the only one who finds it ironic that LDAP, of all the Internet protocols the one most directly aimed at fixing the problem of discoverability, is, itself, undiscoverable:

I happen to know the hostname of my company's LDAP server, so I only need to figure out 7 more settings before I can, you know, find out my colleagues' email addresses.

Uploading this screenshot was an ordeal, by the way. Mac OS has screen-capture hotkeys (Command-Alt-Shift-3 or something absurd like that), but it can't capture just one window. It also comes with a separate screen-capture program (Grab)... which unhelpfully saves your screenshots in TIFF format. (There is no way to configure this.) And Mac OS does not come with any basic image-hacking utility like Paint. Great style, awful usability.

While I'm on a roll:

$ nslookup
> help
The 'help' command is not yet implemented.

Oh, thank you. Thank you so much.

Update: Some great Mac OS screenshot tips are in the comments. (Thank you!)

11 July 2007

Overheard in a car

Buzz (not his real name) is 3; Woody is 22 months.
...
Buzz:  Yes you are!
Woody:  I'm not a are!
Buzz:  Yes you are!
Woody:  I'm not a are!
...

06 July 2007

C puzzle

I was reading source code this morning and came across this curious line in a header file:

JS_STATIC_ASSERT(sizeof(JSGCThing) >= sizeof(JSString));

The effect of this macro is to check at compile time that sizeof(JSGCThing) >= sizeof(JSString). If the condition is not met, compilation fails with an error.

The puzzle is: how does this work? A hint is in the comments.

04 July 2007

Things die

Around seven thousand languages are spoken today. Many are spoken only by a few elderly people. Over 500 such languages are headed for extinction.

Some linguists go much further, claiming that more than half of the languages spoken in 2000 will be extinct by 2100.