From: Bart Schaefer <schaefer@tiny.zanshin.com>
To: Danny Dulai <nirva@ishiboo.com>
Cc: zsh-users@sunsite.auc.dk
Subject: Re: Setting paths with ~'s in values.
Date: Mon, 22 Feb 1999 20:58:54 -0800 (PST) [thread overview]
Message-ID: <14034.13710.335334.486111@c-bart.amazon.com> (raw)
In-Reply-To: <19990222172007.61479@bleep.ishiboo.com>
Danny Dulai writes:
> Quoting Bart Schaefer (schaefer@brasslantern.com):
> >
> > for t_path in $(<${HOME}/.zpaths)
> > do
> > if
> > [[ -d $t_path ]]
> > then
> > eval path=\( $path $t_path \)
> > fi
> > done
>
> This didnt seem to add the paths with ~ in them because the ~ didnt get
> expanded in the test for existence.
Right, silly me. There was even some discussion of file expansion (or
more accurately, lack thereof) in [[ ... ]] expressions not long after
this.
> > and you don't need the extra step of removing the leading colon. But
> > there's a better, faster, smarter way to do the same thing:
> >
> > eval path=\( ${^$(<${HOME}/.zpaths)}'(|)(/)' \)
>
> Aftertmuch of fiddling with this, I found it works if I have NULL_GLOB set.
Didn't I send a follow-up about that? I thought I had ... using (N/)
is exactly the right thing there.
next prev parent reply other threads:[~1999-02-23 8:29 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
1999-02-12 20:17 Larry P . Schrof
1999-02-12 22:05 ` Bart Schaefer
1999-02-12 22:29 ` Bart Schaefer
1999-02-22 22:20 ` Danny Dulai
1999-02-23 4:58 ` Bart Schaefer [this message]
1999-02-23 8:39 ` Danny Dulai
1999-02-24 5:07 ` Bart Schaefer
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=14034.13710.335334.486111@c-bart.amazon.com \
--to=schaefer@tiny.zanshin.com \
--cc=nirva@ishiboo.com \
--cc=schaefer@zanshin.com \
--cc=zsh-users@sunsite.auc.dk \
/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).