Welcome to the GoFuckYourself.com - Adult Webmaster Forum forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact us.

Post New Thread Reply

Register GFY Rules Calendar
Go Back   GoFuckYourself.com - Adult Webmaster Forum > >
Discuss what's fucking going on, and which programs are best and worst. One-time "program" announcements from "established" webmasters are allowed.

 
Thread Tools
Old 08-15-2002, 11:44 AM   #1
ZoiNk
Confirmed User
 
Join Date: Feb 2002
Location: Canada
Posts: 2,370
Need Help with Search and Replace in Linux

For some reason, this code doesn't want to work, what am I doing wrong.

perl -e "s/www.sexhit.com\/cgi-bin\/BAN_record?zoinkme\/0048000097\//www.wetnyoung.com\/216bf2e050c0a28437ea494d6aeb2a1e\//g;" `find . -name "*.*"`

Yes, it runs fine with no syntax errors, it just doesn't replace the instantances of the code. Yes, all one line. Yes, I know it would be case sensative. Any ideas?
Thanks,
ZoiNk
__________________
"People can have the Model T in any color - so long as it's black." - Henry Ford
ZoiNk is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 08-15-2002, 11:55 AM   #2
salsbury
Confirmed User
 
Join Date: Feb 2002
Location: Seattle
Posts: 1,070
you need to use 'perl -pi -e' rather than just 'perl -e'. you might need to escape the ?, too.
__________________
salsbury is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 08-15-2002, 12:10 PM   #3
ZoiNk
Confirmed User
 
Join Date: Feb 2002
Location: Canada
Posts: 2,370
I have got most of it working at the moment, my problem from going through it bit by bit is the ? mark. Problem is I don't know perl/unix commands that well. doing a /? doesn't escape it and just gives me an error. hm... ANyone know how to 'escape' a ? in this command?
ZoiNk
__________________
"People can have the Model T in any color - so long as it's black." - Henry Ford
ZoiNk is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 08-15-2002, 12:13 PM   #4
Wilbo
Confirmed User
 
Wilbo's Avatar
 
Join Date: Mar 2001
Location: Baltimore
Posts: 2,082
I have a kick ass linux search and replace script, hit me on ICQ or email. 7800287 wilbo at wilbo dot com
Wilbo is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Post New Thread Reply
Go Back   GoFuckYourself.com - Adult Webmaster Forum > >

Bookmarks



Advertising inquiries - marketing at gfy dot com

Contact Admin - Advertise - GFY Rules - Top

©2000-, AI Media Network Inc



Powered by vBulletin
Copyright © 2000- Jelsoft Enterprises Limited.