Over a million developers have joined DZone.
{{announcement.body}}
{{announcement.title}}

Multiple File Search And Replace

DZone's Guide to

Multiple File Search And Replace

·
Free Resource
perl -pi -w -e 's/search/replace/g;' *.txt

Bear in mind what's between the single quotes after the -e option is a line of Perl code and the search argument is a regular expression, so some characters will have special meanings. You can escape special characters (like the forward-slash, dot, caret, dollar sign, and so on) by preceeding them with a back-slash.
Topics:

Opinions expressed by DZone contributors are their own.

THE DZONE NEWSLETTER

Dev Resources & Solutions Straight to Your Inbox

Thanks for subscribing!

Awesome! Check your inbox to verify your email so you can start receiving the latest in tech news and resources.

X

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}