tobold.org

correct • elegant • free

△ comp.unix.shell △

◅ How to display a paragraph instead of a line with grep?

Attaching files to email ▻

'eval' question

In article <dLsi3.1282$KM3.331819@burlma1-snr2>,
Barry Margolin  <barmar@bbnplanet.com> wrote:
>eval ${foo}=foo

rc does this particularly well.

    ; x = foo
    ; $x = bar
    ; echo $x is now set to $$x
    foo is now set to bar

The notation is convenient enough that you can use it like an
associative array in awk or Perl.

Tim.
--
Tim Goodwin   | "You don't need to do drugs in order to
University of | think that the government's policies are
Leicester, UK | stupid and dangerous." -- David Bancroft

Original headers:

From: tjg@ltpcg.star.le.ac.uk (Tim J Goodwin)
Newsgroups: comp.unix.admin,comp.unix.shell,comp.unix.programmer
Subject: Re: 'eval' question
Date: 13 Jul 1999 11:33:15 +0100
Organization: University of Leicester, UK
Message-ID: <7mf4m1$up6$1@ltpcg.star.le.ac.uk>
References: <378A4EAC.7F78F4D3@adm.com>
  <dLsi3.1282$KM3.331819@burlma1-snr2>

△ comp.unix.shell △

◅ How to display a paragraph instead of a line with grep?

Attaching files to email ▻