From: Bart Schaefer <schaefer@brasslantern.com>
To: zsh-workers@zsh.org
Cc: Marco Hinz <mh.codebro@gmail.com>
Subject: Re: [patch] Fix VCS_INFO_reposub's whitespace handling
Date: Sun, 28 Sep 2014 11:52:43 -0700 [thread overview]
Message-ID: <140928115243.ZM27229@torch.brasslantern.com> (raw)
In-Reply-To: <20140928171033.GA11234@cheyenne>
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.
next prev parent reply other threads:[~2014-09-28 18:52 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-09-28 17:10 Marco Hinz
2014-09-28 17:39 ` Peter Stephenson
2014-09-28 18:52 ` Bart Schaefer [this message]
2014-09-29 12:23 ` [PATCH] Fix VCS_INFO_reposub's command expansion Frank Terbeck
2014-09-29 13:26 ` Peter Stephenson
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=140928115243.ZM27229@torch.brasslantern.com \
--to=schaefer@brasslantern.com \
--cc=mh.codebro@gmail.com \
--cc=zsh-workers@zsh.org \
/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).