News for hackers. Stuff that matters.
Re:How not to check the validity of an email address by jmadsen on Wednesday September 04, 2013 @03:50AM (#6326191)
>Another legacy app I'm employed to "repair" has one single 'template' for every page on the whole site. Its first ~500 lines conveniently consist of a giant and highly nested if/else clause to set the page variables and inline javascript.

oh, oh! I'm doing one of those. Only, it's a modern, MVC version, so there's actually a couple of dozen controllers with a single function each, and all actions snake through The Great Maze of Ifelsedom to set their rightful values, before traversing it once more on the page view file

Manager: "Uhm, I thought you said changing that label would be a 5 minute task?"

Re:How not to check the validity of an email address by umsm on Wednesday September 04, 2013 @12:06PM (#6328495)
Whenever something like that happens, this is my reference: http://developerexcuses.com
Re:How not to check the validity of an email address by fbernier on Wednesday September 04, 2013 @10:49PM (#6331902)

  git commit -m "$(curl -s developerexcuses.com | sed -n '/<a.*>/{s/<[^>]*>//g;p}')"
Re:How not to check the validity of an email address by brdrak on Thursday September 05, 2013 @12:50AM (#6332247)
Nice bit of sed. :-) Here's the best awk, I could muster:

  awk -F'>' -v RS='<' '/a href/{print$2}'
Re:How not to check the validity of an email address by raldi on Thursday September 05, 2013 @03:00AM (#6332618)
There's also:

    lynx -dump -nolist developerexcuses.com