Page MenuHomeSolus

Add $HOME/.local/bin to PATH by default
ClosedPublic

Authored by xulongwu4 on Dec 23 2021, 9:13 PM.
Tags
None
Referenced Files
F11017919: D12522.id30801.diff
Sun, Aug 6, 7:39 AM
F11015997: D12522.id.diff
Sat, Aug 5, 3:55 PM
F10974569: D12522.diff
Sat, Jul 22, 1:04 AM
F10887527: D12522.id30476.diff
Jun 26 2023, 1:38 PM
F10886529: D12522.id30826.diff
Jun 25 2023, 11:52 PM
F10886351: D12522.id30801.diff
Jun 25 2023, 9:38 PM
F10883188: D12522.diff
Jun 24 2023, 1:35 AM
F10822407: D12522.id30826.diff
Jun 2 2023, 8:44 PM

Details

Summary

Add $HOME/.local/bin to PATH by default

Test Plan

Installed the package and verified $HOME/.local/bin in part of the PATH environment variable

Diff Detail

Repository
R420 bash
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

My 2 cents: I think we should do this to zsh and fish as well. What do you think?
After all, XDG specs say:

User-specific executable files may be stored in $HOME/.local/bin. Distributions should ensure this directory shows up in the UNIX $PATH environment variable, at an appropriate place.

My 2 cents: I think we should do this to zsh

Unless a user has modified /etc/profile which would be overwritten every upgrade, or created an /etc/zprofile or /etc/zsh/zprofile for a custom config.

zsh actually sources /etc/profile https://dev.getsol.us/source/zsh/browse/master/files/zprofile$6 which means it sources /usr/share/defaults/etc/profile.d/*.sh https://dev.getsol.us/source/bash/browse/master/files/profile/profile$4

My 2 cents: I think we should do this to zsh

Unless a user has modified /etc/profile which would be overwritten every upgrade, or created an /etc/zprofile or /etc/zsh/zprofile for a custom config.

zsh actually sources /etc/profile https://dev.getsol.us/source/zsh/browse/master/files/zprofile$6 which means it sources /usr/share/defaults/etc/profile.d/*.sh https://dev.getsol.us/source/bash/browse/master/files/profile/profile$4

In addition, if the user is using a display manager such as lightdm, gdm, or sddm, the /etc/profile is automatically sourced when the display manager starts, and any process in the graphical user interface will inherit the PATH environment. For example, this is where lightdm sources /etc/profile: https://dev.getsol.us/source/lightdm/browse/master/files/lightdm-wrapper$8. No matter the user uses bash, zsh, or fish, he/she should have $HOME/.local/bin in the PATH environment variable after this commit if he/she uses a display manager. To be accurate, zprofile is not sourced if a display manager is used. However, the display manager is where we make sure PATH is set up correctly.

This revision is now accepted and ready to land.Jan 14 2022, 5:26 PM

Needs a rebase.

This revision now requires changes to proceed.Jan 14 2022, 5:30 PM
This revision is now accepted and ready to land.Jan 14 2022, 7:47 PM
This revision was automatically updated to reflect the committed changes.