Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Running "unset path" breaks PATH despite emulation being enabled
- X-seq: zsh-users 22877
- From: Eric Pruitt <eric.pruitt@xxxxxxxxx>
- To: zsh-users@xxxxxxx
- Subject: Re: Running "unset path" breaks PATH despite emulation being enabled
- Date: Sat, 9 Sep 2017 15:38:11 -0700
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:subject:message-id:references:mime-version :content-disposition:in-reply-to:pgp-key:user-agent; bh=X+Brt5uWhMI6bx5XaG8irHKpI0z26WzenLpwO/FwFOQ=; b=jDbLe8Rf5kVA0QLh3xYGO0fYKZ+NUOLsIi2TtOvBq5fCWO90sEls6Ktc8y1dgbrL2V b01Z2wsDkq/uhq6mKSoDEXlyNBRfecQgNPT7pgJQZE+GkbCunoZY3lp3Xn2oCtHMsrCf Zovtre1GCRtguiVYUf3ZLlNOukHuCZUmf8b36Gdzm/rUMv6J/1wl6hnhDlkU/iRdo+qh RRVZ3GliVMqrGGbP22ATopNCGoRJiO/woqlke4zkWVrCW42xX0QXWVfySOCA5dMA8786 OY5cRElVLBoIm73g+PTQyTsHQXeFCJ/x+UDJsSNsc7w00JjF+wzBPo9CD/VcZwFWU4Up DlSQ==
- In-reply-to: <170909152512.ZM9176@torch.brasslantern.com>
- List-help: <mailto:zsh-users-help@zsh.org>
- List-id: Zsh Users List <zsh-users.zsh.org>
- List-post: <mailto:zsh-users@zsh.org>
- Mailing-list: contact zsh-users-help@xxxxxxx; run by ezmlm
- Pgp-key: https://www.codevat.com/pgp.asc#F8601B5D2511B4C3535232488DDDE2E6053692AB
- References: <20170908082917.v5j4vczoq75vs5lk@sinister.lan.codevat.com> <CAHYJk3RD6p7PwRaZSUbJSAE0Bi6_2+NKLC3MV+32Lh+PmzsAdA@mail.gmail.com> <20170909213806.52qezvyk766loeg3@sinister.lan.codevat.com> <170909152512.ZM9176@torch.brasslantern.com>
On Sat, Sep 09, 2017 at 03:25:12PM -0700, Bart Schaefer wrote:
> > Is there a similar value in Z shell or a built-in I can use?
>
> $ZSH_ARGZERO in sufficiently recent versions of the shell will give you
> the equivalent information, you just have to do the path search part
> yourself
This does not seem to be the case:
playground$ cp $(which bash) $(which zsh) .
'/home/ericpruitt/.local/bin/bash' -> './bash'
'/usr/bin/zsh' -> './zsh'
playground$ (PATH=/ ./bash -c 'echo $BASH')
/tmp/tmp.FsPM5kO6Sn/playground/bash
playground$ (PATH=/ ./zsh -c 'echo =$ZSH_NAME')
zsh:1: zsh not found
I'm not sure if I misunderstood or didn't clearly explain what I wanted.
What want is for Z shell to return is the name to the invoked
interpreter which is what $BASH shows even when $PATH doesn't contain
Bash.
Eric
Messages sorted by:
Reverse Date,
Date,
Thread,
Author