Thread: sed and hex
View Single Post
  #6   (View Single Post)  
Old 10th July 2008
robbak's Avatar
robbak robbak is offline
Real Name: Robert Backhaus
VPN Cryptographer
Join Date: May 2008
Location: North Queensland, Australia
Posts: 366

I'm sure if you thought about it, you'd work this one out.

accesslog |sed > accesslog1 Change one made
accesslog |sed > accesslog1 Change two made.

i think you wanted

accesslog |sed > accesslog1 Change one made
accesslog1 |sed > accesslog2 Change two made to file that has change 1 made.

[wrong]Oh, by the way, take a look at the -i option - it allows you to edit the file in-place: it changes the original file.[/wrong] apparently, OpenBSD's sed does not have this. Caught out again.
The only dumb question is a question not asked.
The only dumb answer is an answer not given.

Last edited by robbak; 10th July 2008 at 09:00 AM. Reason: Once again, caught out by BSD differences.
Reply With Quote