[Gllug] Poor scripting?!
John Edwards
john at cornerstonelinux.co.uk
Tue Mar 11 15:36:27 UTC 2008
On Tue, Mar 11, 2008 at 02:41:16PM +0000, Henrik Morsing wrote:
> Hi, I've had a look and help from the #gllug folks (thanks!), does
> this look like it would do the same job, called as 'rename
> s/cerprod/$CRMDB/ s/medprod/$CRMDB /cerillion'?
<snip>
Is there any reason you aren't using Perl's own rename program?
find . -iname "*pattern*" -print0 | xargs -r0 rename 's/pattern/replacement/g'
Of course you may have too many directories for rename to process as
arguments. It certain works with several thousand.
--
#---------------------------------------------------------#
| John Edwards Email: john at cornerstonelinux.co.uk |
#---------------------------------------------------------#
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 196 bytes
Desc: Digital signature
URL: <http://mailman.lug.org.uk/pipermail/gllug/attachments/20080311/6b16353e/attachment.pgp>
-------------- next part --------------
--
Gllug mailing list - Gllug at gllug.org.uk
http://lists.gllug.org.uk/mailman/listinfo/gllug
More information about the GLLUG
mailing list