The UNIX and Linux Forums  
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Dummies Questions & Answers
.
google unix.com




Thread: sexist filter
View Single Post in the UNIX and Linux Forums - Click on the Thread or Permalink to View Entire Thread -->
  #2 (permalink)  
Old 12-08-2004
zazzybob's Avatar
zazzybob zazzybob is offline Forum Advisor  
Registered Geek
  
 

Join Date: Dec 2003
Location: Melbourne, Australia
Posts: 2,100
Hmm... I have never heard of anything like this and couldn't turn anything up during a quick google, but it'd be fairly straightforward (if not lengthy) to write your own.

Code:
#!/usr/bin/perl

while (<>) {
  $_=~s/Mailman/Postal Carrier/gi;
  $_=~s/Mailwoman/Postal Carrier/gi;
  print "$_";
}
Then
$ ./filter.pl my_sexist_file

Unfortunately, you'd need to add a ton of rules covering all sexist eventualities! It'd probably run as slow as hell once you've got a few rules in there too.

Cheers
ZB