From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 9702 invoked by alias); 3 Jan 2015 21:42:21 -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: 19682 Received: (qmail 22175 invoked from network); 3 Jan 2015 21:42:08 -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 X-Originating-IP: [86.6.153.127] X-Spam: 0 X-Authority: v=2.1 cv=AoZg3YNP c=1 sm=1 tr=0 a=39NrsSuza2clQiZR/7fYWQ==:117 a=39NrsSuza2clQiZR/7fYWQ==:17 a=kj9zAlcOel0A:10 a=NLZqzBF-AAAA:8 a=G3B24rPlH5Ticc4SyKcA:9 a=CjuIK1q_8ugA:10 Date: Sat, 3 Jan 2015 21:42:04 +0000 From: Peter Stephenson To: zsh-users@zsh.org Subject: Re: symlink chain. Message-ID: <20150103214204.04a69ab7@ntlworld.com> In-Reply-To: <54A85B6C.4020103@eastlink.ca> References: <549E3A7B.9010209@eastlink.ca> <20150102170307.7d2e644a@ntlworld.com> <54A6E6B1.6070201@eastlink.ca> <20150102212422.3a761af5@ntlworld.com> <54A7136C.1060102@eastlink.ca> <20150102222140.1303a633@ntlworld.com> <54A72CEF.9090102@eastlink.ca> <54A740F3.4040902@eastlink.ca> <150102210337.ZM22099@torch.brasslantern.com> <54A783C3.3000006@eastlink.ca> <150102231734.ZM22168@torch.brasslantern.com> <54A82374.1030208@eastlink.ca> <150103120252.ZM23074@torch.brasslantern.com> <54A85B6C.4020103@eastlink.ca> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit On Sat, 03 Jan 2015 13:13:16 -0800 Ray Andrews wrote: > Conversely, the man page could > explain that -m and -a are incompatible with full path filenames, but > that's not going to happen either. There's no reason not to document what the basic intention of whence is, to avoid people doing dodgy experiments with dodgy results. The key hint at the moment is where it says it indicates how the argument would be used as a command *name*, which sort of implies full paths aren't very useful, but it doesn't actually spell this out. diff --git a/Doc/Zsh/builtins.yo b/Doc/Zsh/builtins.yo index b4f4b67..49c2c11 100644 --- a/Doc/Zsh/builtins.yo +++ b/Doc/Zsh/builtins.yo @@ -2087,6 +2087,11 @@ item(tt(whence) [ tt(-vcwfpamsS) ] var(name) ...)( For each name, indicate how it would be interpreted if used as a command name. +tt(whence) is most useful when var(name) is only the last path component +of a command, i.e. does not include a `tt(/)'; in particular, pattern +matching only succeeds if just the non-directory component of the command is +passed. + startitem() item(tt(-v))( Produce a more verbose report. @@ -2119,7 +2124,7 @@ throughout the command path. Normally only the first occurrence is printed. ) item(tt(-m))( -The arguments are taken as patterns (should be +The arguments are taken as patterns (pattern characters should be quoted), and the information is displayed for each command matching one of these patterns. ) pws