Results 1 to 3 of 3
Hi, I have a file in the format:
*@domain1.com*@domain2.com*@domain3.com
etc.
I want to print out this file with domain1.com domain2.com etc on a new line so I can do something ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
- 04-04-2006 #1Just Joined!
- Join Date
- Apr 2006
- Posts
- 2
File processing question
Hi, I have a file in the format:
*@domain1.com*@domain2.com*@domain3.com
etc.
I want to print out this file with domain1.com domain2.com etc on a new line so I can do something like ./script >> domains.new
and have each domain on a separate line.
I've tried fiddling with awk, grep and perl to achieve this but my programming skills are lacking and can't seem to do it.
Can someone help?
Thanks!
- 04-04-2006 #2Linux Enthusiast
- Join Date
- Jun 2005
- Posts
- 668
not perfect, but it worksCode:echo "*@domain1.com*@domain2.com*@domain3.com" | tr --delete "@" | tr "*" "\n" > domains.new
- 04-05-2006 #3Just Joined!
- Join Date
- Apr 2006
- Posts
- 2
You're a star! Thank you


Reply With Quote
