Support > Ubuntu

Multiple entriesin $PATH

(1/1)

Keith:
Ubuntu 16.04 on Lenovo Thinkpad T500

My original $PATH was:
/usr/local/sbin:
/usr/local/bin:
/usr/sbin:
/usr/bin:
/sbin:
/bin:
/usr/games:
/usr/local/games:
/snap/bin:
where I have separated the entries for clarity.

I modified my .profile file as follows to include two more directories in $PATH:
# set PATH so it includes user's private bin directories
PATH="$PATH:$HOME/.bin:$HOME/.local/bin"

but $PATH now looks like this:
/usr/local/sbin:
/usr/local/bin:
/usr/sbin:
/usr/bin:
/sbin:
/bin:
/usr/games:
/usr/local/games:
/snap/bin:
/home/keith/.bin:
/home/keith/.local/bin:
/home/keith/.bin:
/home/keith/.local/bin

Can anyone tell me why my personal paths are present twice in the $PATH variable?
It's not a problem in practice, but really annoying that I can't find the reason for it!

Navigation

[0] Message Index

Go to full version