Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: [[ -x =command ]]
- X-seq: zsh-users 12039
- From: Atom Smasher <atom@xxxxxxxxxxx>
- To: zsh-users@xxxxxxxxxx
- Subject: Re: [[ -x =command ]]
- Date: Thu, 18 Oct 2007 09:39:47 +1300 (NZDT)
- In-reply-to: <2d460de70710170455j11cfaa80wec4d1d556bfed41c@xxxxxxxxxxxxxx>
- Mailing-list: contact zsh-users-help@xxxxxxxxxx; run by ezmlm
- Openpgp: id=0xB88D52E4D9F57808; algo=1 (RSA); size=4096; url=http://atom.smasher.org/pgp.txt
- References: <20071016210548.26560.qmail@xxxxxxxxxxx> <20071016211319.GA2910@xxxxxxxxxxxxxxx> <20071016214100.62242.qmail@xxxxxxxxxxx> <20071017094414.GA5383@xxxxxxxxxxxxxxx> <20071017113432.GA13054@mastermind> <2d460de70710170455j11cfaa80wec4d1d556bfed41c@xxxxxxxxxxxxxx>
On Wed, 17 Oct 2007, Richard Hartmann wrote:
The canonical way to do this according to 'From Bash to Z Shell' (hi
Peter) is to use whence -p foo. Apparently, whence is what zsh uses
internally, anyway. If you are concerned about cluttering your $PAGER,
basename $(whence ls) is an option.
====================
taking it a step further into zsh-ization...
PAGER=${$(whence -p most):t}
aesthetic issues aside, is there any reason not to include the full path
of the pager in PAGER? the only reason i can think of is if it's defined
in one zshrc used on multiple systems ("/usr/bin/most" or
"/usr/local/bin/most"?) but if it's assigned dynamically, it should be
safe with a full path.
--
...atom
________________________
http://atom.smasher.org/
762A 3B98 A3C3 96C9 C6B7 582A B88D 52E4 D9F5 7808
-------------------------------------------------
"Most peoples' idea of individuality is to find a
subculture or clique and conform to that."
-- Kevin Tulppo
Messages sorted by:
Reverse Date,
Date,
Thread,
Author