There's a rename (sometimes also called prename) program that's shipped with Perl. You can use it for this task:
rename "s/\.xml$/.txt" *.xml
In reply to Re: perl code to replace
by moritz
in thread perl code to replace
by littlemonk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |