Joe Maller.com

Smart vs. Hip

Bruce IM’d with a quote I hadn’t seen in years:

>”Hip is transitory. Smart endures. Hip is defined by others. Smart is defined by intelligence. Hip is only for the moment. Smart is timeless. Hip is driven by trends. Smart is driven by performance. Hip is perpetually looking over your shoulder. Smart is making your own decisions. Hip is mango-chestnut gelati. Smart is chocolate ice cream. Hip is often difficult to define. Smart is always logically defensible. Hip is flash. Smart is substance. Hip is something that looks cool. Smart is something that works. Hip talks the talk. Smart walks the walk. Hip gets you a $300 a week cocaine habit. Smart gets you a big raise and the corner office.” 

He remembers it from a xeroxed handout in one of Brad Durham’s classes we both had at Art Center sometime in the very early 90s.

Amazingly, that only appears to be in Google once, on a seemingly abandoned Tripod page. Nothing in the Usenet archives and most non-Google search engines couldn’t even find the one tripod page.

Anyone remember where this is from or who wrote it?

*update:* also posted to Google Answers

Share |

link: Jul 12, 2006 3:44 pm
posted in: misc.

EXIF and the Unix Strings command

I got an email over the weekend pointing out a bug in my iPhoto Date Reset if an original image contained a single-quote in its name. Most all of my iPhoto images were imported from the camera, so I hadn’t seen this before, but I’m pretty sure I’ve already gotten it fixed.

While fixing that, I did a little revising of the EXIF sniffing script. I was using a one-line Perl snippet to scrape the date out of the first kilobyte of the file. Here’s the command broken across several lines

 perl -e 'open(IMG, q:[ABSOLUTE PATH}:);
 read(IMG, $exif, 1024); 
 $exif =~ s/\n/ /g; 
 $exif =~ s/.*([0-9]{4}(?::[0-9]{2}){2} [0-9]{2}(?::[0-9]{2}){2}).*$/$1/g;
 print STDOUT $exif;'

That worked, but perl one-liners usually need to be enclosed in single-quotes, since AppleScript was filling in the path, single-quotes in the name broke the script. I’m not that fluent in Perl, so there’re probably better ways of doing that.

But then I stumbled across the Unix Strings command. This basically does most of what I was doing. It scrapes a binary file (meaning non-text) and extracts anything that seems to be a string. The output from JPEGs often contains a bunch of gibberish, but right above the gibberish is every unencoded string from the EXIF header.

Using strings, sed for the pattern and head to trim, that somewhat convoluted perl script became this trim little shell script:

 strings [ABSOLUTE PATH] | sed -E -n '/([0-9]{4}(:[0-9]{2}){2} [0-9]{2}(:[0-9]{2}){2})/p' | head -n1

They’re both essentially instant on my computer so I’m not going to bother building a test to figure out which is actually faster.


AppleScript source links from TextMate

AppleScript’s URL Protocol Support allows the full source code of an AppleScript to be shared through an encoded URL. Here’s a short little TextMate Command for converting AppleScripts to encoded URLs.

Create a new command in TextMate’s AppleScript bundle with the following code:

#!/usr/bin/env ruby -KA -rcgi
src = CGI.escape(STDIN.read)
src = src.gsub('+', '%20')
src = 'applescript://com.apple.scripteditor?action=new&script=' + src
`echo -n "#{src}" | pbcopy`
print "The URL encoded AppleScript was copied to the clipboard"

There’s no reason this idea can’t be used for all sorts of stuff. So why not make it easier, it’s not AppleScript, but here’s that code in Script Editor for easier copying.

This is exceptionally fast, much faster than Apple’s provided encoding script. As an extreme example, converting the 558 lines of my iPhoto Date Reset script took just under a minute using Apple’s script. The little Ruby script in TextMate does it instantly. (running the AppleScript in Script Editor with the Event Log Window open took nearly 7 minutes.)

Update: I committed this command to the TextMate Bundles repository and it’s now included in the default set of Bundles shipping with TextMate. (And slightly improved by other TextMate bundle developers)

Share |

link: May 24, 2006 1:43 pm
posted in: misc.
Tags: , , ,

RFC 822 Dates with AppleScript

Here’s a little AppleScript subroutine which converts date objects into correctly formatted RFC date strings: RFCdate() (click to open in Script Editor)

This is a timesaver for anything related to RSS, which requires dates be in the RFC 822 format, ie. Wed, 24 May 2006 01:30:22 -0400


Avon Walk for Breast Cancer [research]

My cousin Sarah, a breast cancer survivor, will be participating in her first Avon Walk for Breast Cancer on July 8-9 in San Francisco, she has been using the http://thebustboosters.com/breast-actives-full-product-review products and she has recovered pretty well. She already met her fundraising goals, but it’d be great if she raised a little more.

Share |

link: May 10, 2006 10:36 pm
posted in: misc.

Original Star Wars and HiDef DVDs

John Gruber linked to the news that Lucas is giving in to demand (eg. money) and will finally release the Star Wars trilogy on DVD in their original, unaltered theatrical format. Han shoots first. John writes:

Bastards. I broke down and finally bought the current DVD trilogy collection just a few months ago now I’ve got to pay for it yet again just to get the versions of the films that I really want.

Hold your wallet. The release will be in SD, despite the news that HD DVDs will start appearing in stores this summer. Lucas, who is as brilliant a money-maker as he is a horrible dialog-writer, will rake in tons of money selling an obsolete DVD. All the Star Wars films will be available again in HiDef soon enough. And too many people will buy them all for the third, fourth or fifth time.

Lucas isn’t alone. All the studios are flooding the DVD market right now to sell as much as possible before the switch to Blu-Ray or HD-DVD.

Supposedly the porn industry likes likes Blu-Ray best, but you’d have to be delusional to think physical pornography sales are anywhere near as strong as they were before the Internet. Still, porn is generally credited with choosing VHS over BetaMax, at least this time they seem to be going with the better format.

Personally, I think HD-DVD may win this time. Not because it’s better, but because “Blu-Ray” is a dumb name. Ask any non-technical consumer what they want for their new HD TV, HD-DVDs or Blu-Ray disks. Sure a certain percentage of people will have Blu-Ray explained to them, “see, they’re both HD,” but how many will buy on name alone?

Never mind that the name itself looks (and sounds) like blurry. Not what you want to hear when dropping a lot of money to replace a bunch of movies you bought in SD a few years ago.

And so the studios might be slitting their own throats. Movie attendance is down over the past several years. Partly movies are kind of boring now, also suspense and action movies keep dancing around what’s really scary. But the studios now want consumers to re-buy movies they just bought. The great DVD migration wasn’t that long ago, most DVDs were probably purchased within the past 5 years. But now Hollywood wants everyone to buy those movies yet again, and they’re going to spend a fortune on conversion and manufacturing in a bet that consumers will buy the new disks. And if we don’t? Lots of bankruptcies.


If they were called poofter penguins or something…

Apparently Sea World in Queensland are renaming their Fairy Penguins to “Little Penguins” in a pathetically unnecessary grasp at political correctness.

This quote by Gold Coast Breakers chairman Kamahl Fox is the highlight

“I wouldn’t be upset by fairy penguins at all. I don’t think our community is that sensitive about those things. If the penguins were called poofter penguins or something more direct then it might be a problem, but I don’t see the name fairy penguin as a mickey-take at all.”

No word on how New York’s own “fairy” penguins received the news.

Wikipedia, as usual, takes all the fun out of this. Apparently “little penguin” is the more common name for Eudyptula minor, Fairy Penguins is the popular Aussie name for the little birds.

I’m all for sticking it to political correctness, but that seems like a rather significant bit of information that should have been included, it’s not like Wikipedia is some obscure resource. The same story as reported by the Herald Sun does sort of mention it at the end, they also had more fun with the title, Gay old time over a little fairy bird

Share |

link: Apr 18, 2006 8:28 pm
posted in: misc.


« Previous PageNext Page »