[CLUE-Tech] RE question

Kevin Cullis kevincu at orci.com
Thu Feb 1 08:01:58 MST 2001


Jeff,

OK, now we're talking. I did the 

cat -vet AMBASS.2

and each end of line has this:

sent to another state to represent his sovereign or country.  By analogy
we^M$

OK, that shows a carrage return in SO, but when I do a \r in sed, it
doesnt change it. Why?

BTW, this is what a new paragraph line looks like:

^I2.  There is no appointment to such ambassadorship until the person^M$

Kevin

"Jeffery C. Cann" wrote:
> 
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> 
> To check for whitespace characters, pass your file through cat:
> 
> $ cat -vet file.txt
> 
> Jeff
> 
> On Monday 29 January 2001 22:43, Kevin Cullis wrote:
> > What I found out is that I was doing REs correctly, but that the display
> > showed the tab character just like it is in a RE (as an \t).
> >
> > Kevin
> >
> > Kevin Cullis wrote:
> > > Jeff or anyone,
> > >
> > > I'm having trouble with REs in sed.  I'd like to substitute 5 spaces
> > > with a tab and I'm having trouble with the RE.  This is what I've tried
> > > with the documentation I've read so far:
> > >
> > > sed 's/   */\t/g' AMBASS.2
> > >
> > > This is the result:
> > >
> > > t1.tAn ambassador is a high
> > >
> > > Where am I going wrong?  I understand that the \t is for horizontal
> > > tabs, but I've tried most everything to get it to work, but it ain't
> > > happin'.
> > >
> > > Jeff, I'm curently typing up RE examples which you may want to use in
> > > your KISS session (which I've realized I can't make next month.  If you
> > > want the text file, let me know and we can pass it around for others to
> > > add to the file.



More information about the clue-tech mailing list