tiding up the PATH
I have previously noticed that loading up the list of application available in $PATH
took a long
time in [wmii-lua]{tag/wmiirc-lua}. I recently found out that it was related to me having multiple
duplicates in my [zsh]{tag/zsh} environment.
To clean this up I added the following to my zsh configuration:
typeset -U path cdpath manpath fpath
This removes duplicates from the PATH
, CDPATH
, MANPATH
, and FPATH
environment variables.
Well, technically it removes duplicates from the path
, cdpath
, manpath
, and fpath
arrays;
but these are treated special and updating them automatically generates their respective :
-delimited
environment variables.
Zsh rocks!
Read other posts