From: "Tennis Smith" <tennis_smith@yahoo-remove-to-reply.com>
Subject: Re: Regexp Query/Replace Without Trashing Original Text
Date: Sun, 1 Aug 2004 19:45:00 -0700 [thread overview]
Message-ID: <1091414485.81086@sj-nntpcache-5> (raw)
In-Reply-To: 877jsi3gpu.fsf@thalassa.informatimago.com
Thanks.
-T
"Pascal Bourguignon" <spam@thalassa.informatimago.com> wrote in message
news:877jsi3gpu.fsf@thalassa.informatimago.com...
> "Tennis Smith" <tennis_smith@yahoo-remove-to-reply.com> writes:
>
> > Hi,
> >
> > How can I convert something like this
> >
> > $GLOBAL_VAR
> >
> > to this:
> >
> > $global_array(GLOBAL_VAR)
> >
> > ??
> >
> > Its easy to do a regexp query/replace for "\$[A-Z]", but I don't really
want
> > to change either the leading dollar sign ("$") or the trailing uppercase
> > text (GLOBAL_VAR).
>
> M-x replace-regexp RET \$\([A-Z][A-Z_]*\) RET $global_array(\1) RET
>
> --
> __Pascal Bourguignon__ http://www.informatimago.com/
>
> There is no worse tyranny than to force a man to pay for what he does not
> want merely because you think it would be good for him. -- Robert Heinlein
next prev parent reply other threads:[~2004-08-02 2:45 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-07-31 10:37 Regexp Query/Replace Without Trashing Original Text Tennis Smith
2004-08-01 13:15 ` Kai Grossjohann
2004-08-01 17:34 ` Pascal Bourguignon
2004-08-02 2:45 ` Tennis Smith [this message]
2004-08-02 14:56 ` Yair Friedman
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1091414485.81086@sj-nntpcache-5 \
--to=tennis_smith@yahoo-remove-to-reply.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).