From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 16540 invoked by alias); 28 Sep 2014 18:52:58 -0000 Mailing-List: contact zsh-workers-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Workers List List-Post: List-Help: X-Seq: 33267 Received: (qmail 15475 invoked from network); 28 Sep 2014 18:52:57 -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=-1.9 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.2 From: Bart Schaefer Message-id: <140928115243.ZM27229@torch.brasslantern.com> Date: Sun, 28 Sep 2014 11:52:43 -0700 In-reply-to: <20140928171033.GA11234@cheyenne> Comments: In reply to Marco Hinz "[patch] Fix VCS_INFO_reposub's whitespace handling" (Sep 28, 7:10pm) References: <20140928171033.GA11234@cheyenne> X-Mailer: OpenZMail Classic (0.9.2 24April2005) To: zsh-workers@zsh.org Subject: Re: [patch] Fix VCS_INFO_reposub's whitespace handling Cc: Marco Hinz MIME-version: 1.0 Content-type: text/plain; charset=us-ascii On Sep 28, 7:10pm, Marco Hinz wrote: } } I'm new to zsh internals, but apparently something causes the string } 'foo bar' to be read in as 2 arguments. printf only takes 1 } argument, and so 'bar' just gets appended. } } Could someone point me to the appropriate parameter expansion rule? } } Solution: } } Double-quote ${$(pwd -P)#$base/}. It's the $(pwd -P) that's the problem; $(...) is subject to $IFS split unless quoted. Section 14.4 "Command Substitution" in the docs.