zsh-workers
 help / color / mirror / code / Atom feed
From: Bart Schaefer <schaefer@brasslantern.com>
To: Zsh hackers list <zsh-workers@zsh.org>
Subject: Re: 'whence' question
Date: Tue, 11 Nov 2014 11:33:13 -0800	[thread overview]
Message-ID: <CAH+w=7Y4LkeTHf+yrwzA1Ex-WAYSMZU9HpBp1on8GYE7PXJbSw@mail.gmail.com> (raw)
In-Reply-To: <54625276.2070901@eastlink.ca>

On Tue, Nov 11, 2014 at 10:16 AM, Ray Andrews <rayandrews@eastlink.ca> wrote:
>
> FIRST OCCURRENCE  OF FILES ONLY? I'D EXPECT THE '-m' FORM TO BE
> THE DEFAULT, THE DOC IS CLEAR THAT ALL COMMAND FORMS ARE
> SEARCHED.

I'm not sure what you're hollering about.  Searching all forms has
nothing to do with whether the search is for a literal string (which
is the default) or for a pattern (which requires the -m option to be
explicitly stated).  "All command forms" means aliases, reserved
words, and functions, and your example found those aliases.

> $ whence zsh*
> /usr/local/bin/zsh
> /usr/local/bin/zsh-RayStyle1

I'm 99.75% sure that you'd see

$ echo zsh*
zsh
zsh-RayStyle1

and that this is entirely the reason you get the above result from whence.

> $ whence  "zsh*"
> (nothing)

Well, yeah.  You did not specify -m and there is no command or
function whose name literally is zee ess aitch star, so whence found
nothing.

> REMOVE  '-v' AND ALIASES 'BECOME' FILES! :(

Well, no, they don't become files, the become whatever is on the
right-hand-side of the alias.

% alias zsh='echo good golly miss molly'
% whence -a zsh
echo good golly miss molly
/bin/zsh

It's not the fault of "whence" that you don't find this to be as
useful as the -v output.


  reply	other threads:[~2014-11-11 19:33 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <545A6D66.3080500@eastlink.ca>
     [not found] ` <1458.1415209763@thecus.kiddle.eu>
     [not found]   ` <20141105180035.22f6e9b1@pwslap01u.europe.root.pri>
     [not found]     ` <141105204330.ZM2973@torch.brasslantern.com>
2014-11-06 21:10       ` Peter Stephenson
2014-11-06 21:58         ` Bart Schaefer
2014-11-08 20:41           ` Peter Stephenson
2014-11-09 18:51             ` Bart Schaefer
2014-11-10  5:15               ` 'whence' question and others Ray Andrews
2014-11-10  8:20                 ` Bart Schaefer
2014-11-10  8:23                   ` Bart Schaefer
2014-11-10 16:57                   ` Ray Andrews
2014-11-10 19:53                     ` Vin Shelton
2014-11-11 16:52               ` 'whence' question Ray Andrews
2014-11-11 19:14                 ` Bart Schaefer
2014-11-11 19:38                   ` Bart Schaefer
2014-11-11 20:22                   ` Ray Andrews
2014-11-11 18:16               ` Ray Andrews
2014-11-11 19:33                 ` Bart Schaefer [this message]
2014-11-11 20:40                   ` Ray Andrews
2014-11-08 21:55           ` Bart Schaefer
2014-11-10 10:04             ` 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='CAH+w=7Y4LkeTHf+yrwzA1Ex-WAYSMZU9HpBp1on8GYE7PXJbSw@mail.gmail.com' \
    --to=schaefer@brasslantern.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).