From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20494 invoked by alias); 19 Dec 2014 05:19:32 -0000 Mailing-List: contact zsh-users-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Users List List-Post: List-Help: X-Seq: 19588 Received: (qmail 27397 invoked from network); 19 Dec 2014 05:19:30 -0000 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,HTML_MESSAGE, RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.2 X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=vjwgE+rRu7uz9aYowJ48yTgqj/NL+wlV5Y1bRfOTcBk=; b=jy/HVPUH5Nr/+sQ1FS0fHxF7TrUCfO5a1D81qvb7riXzg5Ym0EVkIvvTCvp8HbdTBO SYqF9QazMHs8DGK3hTRikR5pLRzHEmWW9WmnSVqo1C929G8johxfUtveKjP+vTzrlnxR 4a6JxxakNHBU9xykE69FQxXfkH4BQaoFcimleakMqXFJEe1Bn+Ug21kV6UC/wIzz4hP9 8RfzpMoq67HdvIjZ79GgtrJbF7REgji9rU832VOIWcc1NRelvenxUTTFoESh+gjsevNV 8XKx3AeckdWODVLL5E4LfjNOOpdiqAZ374CMD+H82YVpIUwun6d2+4bbrnUvl8BheOvu l17Q== X-Gm-Message-State: ALoCoQlFRIDp/zOBaMKPOpGOD2TRHCWDBD3dY66uPRG+z/UpDtwYQxLRgltbQ4DAt3c3j9FRNM+t MIME-Version: 1.0 X-Received: by 10.112.101.100 with SMTP id ff4mr5812851lbb.94.1418966368586; Thu, 18 Dec 2014 21:19:28 -0800 (PST) In-Reply-To: <1BF8BB5F-7A65-4837-843F-48D76E1BC7EB@macports.org> References: <54937E5B.2020008@eastlink.ca> <141218190653.ZM16331@torch.brasslantern.com> <1BF8BB5F-7A65-4837-843F-48D76E1BC7EB@macports.org> Date: Thu, 18 Dec 2014 21:19:28 -0800 Message-ID: Subject: Re: surprise with echo From: Kurtis Rader To: =?UTF-8?Q?Lawrence_Vel=C3=A1zquez?= Cc: Zsh Users Content-Type: multipart/alternative; boundary=001a1135e298592a01050a8adae5 --001a1135e298592a01050a8adae5 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable You apparently missed my point that script was meant to be run by a Plan 9 rc shell. See the "#!/usr/bin/rc" at the top. It was meant to exhibit the behavior of the shell the zsh RC_EXPAND_PARAM option is meant to emulate. On Thu, Dec 18, 2014 at 8:39 PM, Lawrence Vel=C3=A1zquez wrote: > > On Dec 18, 2014, at 11:14 PM, Kurtis Rader wrote: > > > I created a shell script containing > > > > #!/usr/bin/rc > > > > echo echoing1: $@ > > echo echoing2: $* > > echo echoing3: $* $@ killed > > echo echoing4: $@ $* dead > > > > echo aaa^$*^bbb > > echo ccc^$@^ddd > > This doesn't reproduce the environment Ray had because your positional > parameters get substituted into their own words. > > % cat /private/tmp/x.zsh > echo echoing1: $@ > echo echoing2: $* > echo echoing3: $* $@ killed > echo echoing4: $@ $* dead > echo aaa^$*^bbb > echo ccc^$@^ddd > echo > echo "echoing5: $@" > echo "echoing6: $*" > echo "echoing7: $* $@ killed" > echo "echoing8: $@ $* dead" > % zsh !$ > zsh /private/tmp/x.zsh > echoing1: > echoing2: > echoing3: killed > echoing4: dead > aaa^^bbb > ccc^^ddd > > echoing5: > echoing6: > echoing7: killed > echoing8: dead > % zsh -P !$ > zsh -P /private/tmp/x.zsh > echoing1: > echoing2: > echoing3: killed > echoing4: dead > > > > > echoing6: > > > % > > vq --=20 Kurtis Rader Caretaker of the exceptional canines Junior and Hank --001a1135e298592a01050a8adae5--