Re: Modifying text in a large file
Re: Modifying text in a large file
- Subject: Re: Modifying text in a large file
- From: Rob Stott <email@hidden>
- Date: Mon, 20 Oct 2003 17:04:29 +0100
On 20 Oct 2003, at 16:11, Deivy Petrescu wrote:
On Monday, Oct 20, 2003, at 09:27 US/Eastern, christian vick wrote:
I want to search a string and then replace the entire line with
another
string (or delete the line). This in a large text file (50 MB)....
Read "man sed"
If necessary you can create a file of things to change. It is
extremely fast.
Hi Christian
I had a similar problem and dealt with it in the same way Deivy
suggests. I'd recommend it, its remarkably quick. There's a good
tutorial at...
http://www.osxfaq.com/Tutorials/LearningCenter/
...its much easier than trying to figure stuff out via the man pages.
Look up the sections on 'sed' and 'grep' for help with searching /
searching and replacing.
You can do some pretty powerful things if you fancy having a dabble
with Perl too, if you're feeling brave!
r.
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.