[Wellington-pm] tidying up output from naughty backticked commands?

Sam Vilain sam at vilain.net
Mon Sep 13 00:31:27 CDT 2004


Steve Wray wrote:
> Currently I have this;
> my $messy_mode = `svn propget file:mode "$filename"`;
> my ($tidy_mode) = $messy_mode =~ m/^(\d+)\D+$/;

s/\s//xg will strip all whitespace in the string

This distribution and related modules from clkao probably has lots of 
pieces you could use, if you're wrapping SVN:

http://search.cpan.org/~clkao/SVK-0.20/bin/svk

-- 
Sam Vilain, sam /\T vilain |><>T net, PGP key ID: 0x05B52F13
(include my PGP key ID in personal replies to avoid spam filtering)


More information about the Wellington-pm mailing list