Bug 1583227
Summary: | ~/.local/bin is not added at the top of the user PATH even if is documented by systemd and XDG spec | ||
---|---|---|---|
Product: | Red Hat Enterprise Linux 7 | Reporter: | Sorin Sbarnea <ssbarnea> |
Component: | bash | Assignee: | Siteshwar Vashisht <svashisht> |
Status: | CLOSED NOTABUG | QA Contact: | BaseOS QE - Apps <qe-baseos-apps> |
Severity: | medium | Docs Contact: | |
Priority: | unspecified | ||
Version: | 7.7-Alt | CC: | jperrin, kdudka |
Target Milestone: | rc | ||
Target Release: | --- | ||
Hardware: | All | ||
OS: | All | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | If docs needed, set a value | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2018-05-28 15:10:27 UTC | Type: | Bug |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: |
Description
Sorin Sbarnea
2018-05-28 13:53:18 UTC
It should be set by ~/.bash_profile on rhel 7. This is the default bash_profile: $ cat ~/.bash_profile # .bash_profile # Get the aliases and functions if [ -f ~/.bashrc ]; then . ~/.bashrc fi # User specific environment and startup programs PATH=$PATH:$HOME/.local/bin:$HOME/bin export PATH Either you have modified ~/.bash_profile on your system or you are overriding PATH after ~/.bash_profile is sourced. It was my mistake as I used su to change user and I forgot to use `-l` to specify the login. In that case the PATH is not updated and it does use the default, which does not include it. One thing that I observed is that the user bin path is added to the end of the list and this could be problematic because if users installs his own tool, that tool will never be used as long there is one installed at system level. I am not sure if the spec(s) do mention the precedence order of the PATHs as my impression is that user one should take precedence, allowing user-override. > One thing that I observed is that the user bin path is added to the end of the list and this could be problematic because if users installs his own tool, that tool will never be used as long there is one installed at system level. It is already being discussed in fedora-devel[1]. [1] https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org/thread/OXXC5NOZP37W2F6GHV6P5E6K22QHOBNJ/ Thanks for posting the link to Fedora discussion. Apparently the discussion took place about 3 weeks ago and didn't get any clear outcomes. A small summary: - Debian/Ubuntu now adds that to the top of the PATH, as expected. - security concerns are irrelevant because any user can already alter PATH or create files on his own home directory. *** Bug 1093432 has been marked as a duplicate of this bug. *** |