Usenet comp.unix.tru64 (2000-2013)
 help / color / mirror / Atom feed
* ed...
@ 2001-05-23  8:52 BL Venkatesh
  2001-05-24 12:42 ` ed Bob Harris
  0 siblings, 1 reply; 2+ messages in thread
From: BL Venkatesh @ 2001-05-23  8:52 UTC (permalink / raw)


Hi,

How do I give a search pattern in 'ed' editor for a string that looks
the following:
abc {

Regards,
blv


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: ed...
  2001-05-23  8:52 ed BL Venkatesh
@ 2001-05-24 12:42 ` Bob Harris
  0 siblings, 0 replies; 2+ messages in thread
From: Bob Harris @ 2001-05-24 12:42 UTC (permalink / raw)


[[ This message was both posted and mailed: see
   the "To," "Cc," and "Newsgroups" headers for details. ]]

In article <3B0B7A58.5EBE103C@digital.com>, BL Venkatesh
<bl.venkatesh@digital.com> wrote:

X  How do I give a search pattern in 'ed' editor for a string that looks
X  the following:
X  abc {

I'm not sure I understand the question, since it seems so obvious

        /abc {

will find a line with "abc {" in it.  If you want a regular expression,
then:

        /abc.*{                         # anything between 'c' and '{'
or
        /[a-z][a-z0-9_]*.*{             # any alphanumeric 
or
        /abc[   ][      ]*{             # 'abc' white space '{'
or
        /[a-z][a-z0-9_][        ][      ]*{     # alphanumeric white
                                                # space '{'

are all regular expressions that should find "abc {"

The man page for 'ed' says look at the 'grep' command man page for an
explanation of what regular expressions are supported in 'ed'.

If I misunderstood the question, my apologies.

                                        Bob Harris


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2001-05-24 12:42 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2001-05-23  8:52 ed BL Venkatesh
2001-05-24 12:42 ` ed Bob Harris

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox