[Fix #381] Remove the path_helper workaround
This commit is contained in:
parent
095863e6ae
commit
6fd00449a6
19
README.md
19
README.md
|
@ -33,25 +33,6 @@ version is 4.3.10.
|
||||||
|
|
||||||
5. Open a new Zsh terminal window or tab.
|
5. Open a new Zsh terminal window or tab.
|
||||||
|
|
||||||
### Mac OS X
|
|
||||||
|
|
||||||
If you have administrator privileges, you must fix an Apple-introduced problem
|
|
||||||
in Mac OS X 10.5 Leopard by executing the following command, or BASH and Zsh
|
|
||||||
will have the wrong `PATH` when executed non-interactively.
|
|
||||||
|
|
||||||
sudo chmod ugo-x /usr/libexec/path_helper
|
|
||||||
|
|
||||||
`path_helper` is intended to make it easier for installers to add new paths to
|
|
||||||
the environment without having to edit shell configuration files by adding
|
|
||||||
a file with a path to the */etc/paths.d* directory.
|
|
||||||
|
|
||||||
Unfortunately, `path_helper` always reads paths from */etc/paths* set by Apple
|
|
||||||
then paths from */etc/paths.d* set by third party installers, and lastly paths
|
|
||||||
from the `PATH` environment variable set by the parent process, which
|
|
||||||
ultimately is set by the user with `export PATH=...` Thus, it reorders path
|
|
||||||
priorities, and user */bin* directories meant to override system */bin*
|
|
||||||
directories end up at the tail of the array.
|
|
||||||
|
|
||||||
### Troubleshooting
|
### Troubleshooting
|
||||||
|
|
||||||
If you are not able to find certain commands after switching to *Prezto*,
|
If you are not able to find certain commands after switching to *Prezto*,
|
||||||
|
|
|
@ -43,16 +43,9 @@ typeset -gU cdpath fpath mailpath path
|
||||||
# Set the list of directories that Zsh searches for programs.
|
# Set the list of directories that Zsh searches for programs.
|
||||||
path=(
|
path=(
|
||||||
/usr/local/{bin,sbin}
|
/usr/local/{bin,sbin}
|
||||||
/usr/{bin,sbin}
|
|
||||||
/{bin,sbin}
|
|
||||||
$path
|
$path
|
||||||
)
|
)
|
||||||
|
|
||||||
for path_file in /etc/paths.d/*(.N); do
|
|
||||||
path+=($(<$path_file))
|
|
||||||
done
|
|
||||||
unset path_file
|
|
||||||
|
|
||||||
#
|
#
|
||||||
# Less
|
# Less
|
||||||
#
|
#
|
||||||
|
|
Loading…
Reference in a new issue