Small Mosaic


Categories:

/books
/career
/codinghorrors
/events
/geekstuff
/justdont
/languages
/languages/bash
/linkshot
/magazines
/meta
/misctech
/movies
/nottech
/operatingsystems
/operatingsystems/linux
/operatingsystems/linux/debian
/operatingsystems/solaris
/perl
/presentations
/programming
/python
/ruby
/security
/security/apache
/security/tools
/serversmells
/services
/services/dns
/sites
/specifications
/sysadmin
/testing
/tools
/tools/commandline
/tools/firefox
/tools/gui
/tools/network
/tools/online
/tools/online/greasemonkey
/tools/puppet
/unixdaemon

Archives:

July 20111
June 20112
May 20113
April 20112
March 20117
January 20111
December 20103
November 20103
August 20101
July 20101
June 20104
May 20102
April 20101
March 20108
February 20101
January 20102
Full Archives

Sat, 15 Jul 2006

HTML Tidy, FireFox Envy and the Command Line
Tidy is a great little HTML lint tool, that goes a lot further than the W3C Validator, but it requires you to remember to run it. The FireFox HTML Validator extension uses tidy and the FireFox status bar at the bottom of the screen to show you tidy output from the current page.

This extension removes the need to run tidy by hand, you get it for free on every page you visit, but it does mean you need to visit any pages you want to run tidy against once you get spoiled by its output. And you will! The biggest annoyance with the tidy command line tool the requirement that pages must be on disk, not on a live website, which isn't what I wanted. The tidy_page.sh command line script is my little wrapper that could; it wraps tidy and wgets the pages for you. It then displays the results and removes the temp file so no traces remain on disk.

With the addition of a little wrapping script around this and I've now got a daily lint check on my main webpages. And you can have one too.

Like this post? - Digg Me! | Add to del.icio.us! | reddit this!

Posted: 2006/07/15 14:00 | /tools/commandline | Permanent link to this entry | This entry and same date


Superman Returns - Good but no Spiderman
I'm not a huge fan of the Man of Steel, I find his comics boring, the Christopher Reeve films were watchable but nothing that stands out from my childhood and Smallville is mostly dull. I'd heard the hype about Superman Returns and considering how well the second X-Men film went I thought I'd give it ago. On opening day. Because it's a comic book based film dammit. And Spiderman 3 is taking TOO LONG. HEAR ME RAIMI?!

I wasn't really grabbed by the film as a whole. While Brandon Routh does a decent enough Superman with enough of a boy scout look to be passable, Kate Bosworth was a very weak Lois Lane compared to all the other incarnations I've seen and I just don't see the appeal of James Marsden. As either Richard White or Cyclops (in the X-Men, the first two of which were also directed by Bryan Singer) he's bought nothing to the screen. He's not a good actor, he's not extreme eye candy and he always looks too much like an everyman. And we've got Clark Kent for that in this film. The special effects were decent if not ground breaking and Kevin Spacey seemed to be the only person enjoying himself. He's not my favourite Lex but he did a decent job.

5/10 - Watchable but don't rush.

Like this post? - Digg Me! | Add to del.icio.us! | reddit this!

Posted: 2006/07/15 13:08 | /movies | Permanent link to this entry | This entry and same date


Don't do This With 'find' - part 1
Hell is other peoples code. -- Not quite Sartre.

I don't mind using other peoples code. I'll even submit patches if I find a problem, but discovering the same mistakes in almost half-a-dozen projects is enough to drive me insane. Here are three common red flags involving the find command and how to get around them:

If you want to be portable, don't use GNU/Linuxisms.

Compare these two commands -

find -name "*.log" # not portable
find . -name "*.log" # works everywhere

The first one works with GNU find so it's fine for (almost) all Linux distributions. It doesn't work on older Solaris, HPUX or AIX machines and saves one dot. Lesson: specify your paths.

Know what happens when you match nothing.

The first example (shown below) works fine as long as it matches. If the find doesn't return anything you get a syntax error.

find . -name "*.tmp" | xargs rm # pray for a .tmp file
find . -name "*.tmp" | xargs -r rm

The second example exits silently if there is nothing for it to do. As noted by Dave Cantrell, the -r option is a GNUism so be careful where you use it. You can also get around this by using find options -exec foo instead of xargs. But that comes with its own baggage. Lesson: Plan for errors.

If you're using GNU/Linuxisms then use them properly.

The GNU utilities add a number of powerful and convenient options. If you've decided that your script only cares about Linux use them and save a lot of hassle.

find . -ls | awk '{ printf("%s %s %d\n", $NF, $5, $7) }' # horrible
find . -printf "%p %u %s\n" # better

The first example is (possibly) more portable but it's horrible. And not something you want to see in an init script. The second one is tied to newer versions of find but is much clearer to read, once you've looked up the escapes using man find. Lesson: Know your options.

Like this post? - Digg Me! | Add to del.icio.us! | reddit this!

Posted: 2006/07/15 12:36 | /codinghorrors | Permanent link to this entry | This entry and same date


Is the DragonLance Movie Happening? We Have a YES!
I played a lot of ADnD at school, and while I only took part in a couple of short DragonLance campaigns, I'm a Forgotten Realms man, the books written by Margaret Weis and Tracy Hickman really grabbed me. Over the years, where ever ADnD fans gathered in sleepy, huddled masses, the topic of a DragonLance movie would occasionally crop up and we'd all say how great it'd be but that it's never happen; looks like we were wrong...

It seems that a DragonLance Movie based on the Dragons of Autumn Twilight is undergoing production. It's going to be animated rather than live action (even though The Lord of the Rings big screen adaption showed what can be done in this genre) and I have to say the news fills me with both excitement and dread.

The idea of seeing those characters bought to life is exciting, I want to know how other people perceive Tanis and Raistlin, but I can remember the Dungeons and Dragons film (which was bad, very bad) and the script is being worked on by George Strayton, 'whose credits include "Cleopatra 2525", "Xena: Warrior Princess" and "Hercules: The Legendary Journeys".', three shows that I've seen and have never inspired me to think the world epic. Well, not in a good way.

These books are some of my favourites, let's hope he's very careful with them.

Like this post? - Digg Me! | Add to del.icio.us! | reddit this!

Posted: 2006/07/15 08:30 | /movies | Permanent link to this entry | This entry and same date


Webcomics and Deadtrees
Another day, another Amazon package... This time it had both the laugh out loud funny Penny Arcade - attack of the Bacon Robots and the ever impressive Megatokyo: Volume 4.

In addition to the comics the Penny Arcade book has a short paragraph of commentary for each cartoon and, fortunately, they're as funny as the cartoons themselves. While Volume 4 of Megatokyo isn't as amusing as the first couple of volumes, and no where near as funny as PA, it's evolving in to a great story full of impressive art. The highlight for me (I've already read all the comics online) is the expanded Circuity, which is a much easier and enjoyable read than the original online version.

Like this post? - Digg Me! | Add to del.icio.us! | reddit this!

Posted: 2006/07/15 08:14 | /geekstuff | Permanent link to this entry | This entry and same date


books career codinghorrors events geekstuff justdont magazines meta misctech movies nottech operatingsystems/linux operatingsystems/linux/debian operatingsystems/solaris perl programming python ruby security security/apache security/tools serversmells services/dns sites sysadmin testing tools tools/commandline tools/firefox tools/gui tools/network tools/online tools/online/greasemonkey tools/puppet unixdaemon

Copyright © 2000-2010 Dean Wilson XML feed logo