zsh-users
 help / color / mirror / code / Atom feed
From: Haakon Riiser <haakon.riiser@fys.uio.no>
To: Dominic Mitchell <dom@happygiraffe.net>
Cc: zsh-users@sunsite.dk
Subject: Re: param expansion flags
Date: Fri, 6 May 2005 18:13:40 +0200	[thread overview]
Message-ID: <20050506161340.GA5078@fox> (raw)
In-Reply-To: <20050506124817.GA81248@ppe.happygiraffe.net>

Dominic,

> I've gotten part of the way there, but I can't figure out the rest.  So
> far, I've gotten it to split out the lines, remove "rake " from the
> front and start putting the initial square bracket in.
> 
>     % arr=( ${${${(f)~~"$(rake -sT)"}#rake }/ *# /[} )
> 
> Can anyone offer me some advice?

This seems to work:

  arr=(${^${${${(f)~~"$(rake -sT)"}}#rake }// *# /[}}])

The only difference is that your expression is now placed into
${^...} so that the trailing ] is appended to every line.

-- 
 Haakon


      parent reply	other threads:[~2005-05-06 16:14 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-05-06 12:48 Dominic Mitchell
2005-05-06 16:11 ` Bart Schaefer
2005-05-07 10:16   ` Dominic Mitchell
2005-05-06 16:13 ` Haakon Riiser [this message]

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

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20050506161340.GA5078@fox \
    --to=haakon.riiser@fys.uio.no \
    --cc=dom@happygiraffe.net \
    --cc=zsh-users@sunsite.dk \
    /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.
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).