From: "Bart Schaefer" <schaefer@candle.brasslantern.com>
To: Will Yardley <william@hq.newdream.net>, zsh-users@sunsite.dk
Subject: Re: $PATH
Date: Tue, 10 Jul 2001 08:17:43 +0000 [thread overview]
Message-ID: <1010710081744.ZM28207@candle.brasslantern.com> (raw)
In-Reply-To: <20010709222813.B15620@hq.newdream.net>
On Jul 9, 10:28pm, Will Yardley wrote:
} Subject: $PATH
}
} noticed that if i do something like:
} PATH=$PATH:/dh/bin
} or whatever, each time i open a new shell (ie if i type 'zsh') my new shell
} has the arg appended twice
}
} is there a simple solution i'm overlooking here?
Use the `path' array instead of the PATH scalar, and use `typeset -U'.
typeset -U path
path=($path /dh/bin)
Recent versions of zsh, e.g. 3.1.9/4.0.x, also allow `typeset -U' of a
colon-separated scalar like PATH, but the above will work in most 3.0.x
versions as well.
--
Bart Schaefer Brass Lantern Enterprises
http://www.well.com/user/barts http://www.brasslantern.com
Zsh: http://www.zsh.org | PHPerl Project: http://phperl.sourceforge.net
prev parent reply other threads:[~2001-07-10 8:20 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-07-10 5:28 $PATH Will Yardley
2001-07-10 8:17 ` Bart Schaefer [this message]
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=1010710081744.ZM28207@candle.brasslantern.com \
--to=schaefer@candle.brasslantern.com \
--cc=william@hq.newdream.net \
--cc=zsh-users@sunsite.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).