Tools to solve perly problems
So, you've got a problem with something perlish. What language do you use to solve it?
My particular problem is that my CPAN-testing machines were all fed off CPAN's RECENT file (eg http://www.cpan.org/RECENT), which would update every few hours. This is apparently no longer being updated, instead there's a much more up-to-date YAML file (http://www.cpan.org/authors/RECENT.recent) that updates within seconds of something hitting the PAUSE. But my ugly lash-up of shell scripts expects the old format, so what's a boy to do?
I *could* write some perl that uses LWP::Simple and YAML to grab the file and parse out the information I need. Alternatively, I could do this:
GET http://www.cpan.org/authors/RECENT.recent \
|grep 'path: id\/.\/..\/' \
|grep '.tar.gz$\|.zip$' \
|sed 's/ *path: id\/.\/..\///g' > RECENT
which fits much better with the rest of the system :-)
Leave a comment