zsh-users
 help / color / mirror / code / Atom feed
* Anonymous array indexing
@ 2000-12-13  1:41 Steve Talley
  2000-12-13  4:04 ` Dan Nelson
  2000-12-13  4:06 ` Bart Schaefer
  0 siblings, 2 replies; 5+ messages in thread
From: Steve Talley @ 2000-12-13  1:41 UTC (permalink / raw)
  To: zsh-users

Hello,

Is there a compact version of the following:

    fred=(one two three)
    export FRED=$fred[2]
    unset fred

I am looking for something like

    export FRED=(one two three)[2]

so that I can avoid having to use the temporary variable fred.
The above doesn't work.  Is there something equivalently short I
can use?  I'm running zsh 3.1.9.

Thanks,

Steve


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

end of thread, other threads:[~2000-12-13 17:39 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2000-12-13  1:41 Anonymous array indexing Steve Talley
2000-12-13  4:04 ` Dan Nelson
2000-12-13  4:06 ` Bart Schaefer
2000-12-13 17:05   ` Steve Talley
2000-12-13 17:39     ` Bart Schaefer

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

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 NNTP newsgroup(s).