You are not logged in.

#1 2020-03-22 23:10:03

Martin
Member
From: Stockholm, Sweden
Registered: 2015-10-01
Posts: 414
Website

[SOLVED] .local/bin not adden to $PATH

Deb 10 but still Helium rather than Lithium.

.profile contains

# set PATH so it includes user's private bin if it exists
if [ -d "$HOME/bin" ] ; then
    PATH="$HOME/bin:$PATH"
fi
# set PATH so it includes user's .local/bin if it exists
if [ -d "$HOME/.local/bin" ] ; then
    PATH="$HOME/.local/bin:$PATH"
fi

Adding $HOME/bin works but not $HOME/.local/bin.

Me confused.

/Martin

Last edited by Martin (2020-03-23 07:44:08)


"Problems worthy of attack
prove their worth by hitting back."
Piet Hein

Offline

#2 2020-03-22 23:36:16

rbh
Member
From: Sweden/Vasterbotten/Rusfors
Registered: 2016-08-11
Posts: 330

Re: [SOLVED] .local/bin not adden to $PATH

Martin wrote:

.profile
[...]
Adding $HOME/bin works but not $HOME/.local/bin.

Yes, its funny. But using .bashrc with

PATH="$PATH:$HOME/bin:$HOME/.local/bin"

works...

Last edited by rbh (2020-03-22 23:37:02)


// Regards rbh

Offline

#3 2020-03-22 23:43:04

damo
....moderator....
Registered: 2015-08-20
Posts: 5,835

Re: [SOLVED] .local/bin not adden to $PATH

Martin wrote:

...
Me confused.

/Martin

So have a look at what .profile has to say...

#
# NOTE this file is not sourced by lightdm when logging in to X sessions.
# Use .xsessionrc for graphical sessions.

So edit .xsessionrc, NOT .profile, if you are using lightdm for login.


Be Excellent to Each Other...
The Bunsenlabs Lithium Desktop » Here
FORUM RULES and posting guidelines «» Help page for forum post formatting
Artwork on DeviantArt  «» BunsenLabs on DeviantArt

Offline

#4 2020-03-23 06:36:57

johnraff
nullglob
From: Nagoya, Japan
Registered: 2015-09-09
Posts: 6,561
Website

Re: [SOLVED] .local/bin not adden to $PATH

rbh wrote:
Martin wrote:

.profile
[...]
Adding $HOME/bin works but not $HOME/.local/bin.

Yes, its funny. But using .bashrc with

PATH="$PATH:$HOME/bin:$HOME/.local/bin"

works...

Usually you want $PATH last, though, so the local directories take precedence.


...elevator in the Brain Hotel, broken down but just as well...
( a boring Japan blog (currently paused), idle Twitterings and GitStuff )

Introduction to the Bunsenlabs Lithium Desktop

Offline

#5 2020-03-23 07:12:53

linux_user
Member
Registered: 2016-11-04
Posts: 458

Re: [SOLVED] .local/bin not adden to $PATH

Just an FYI: if OP is using tmux (a login shell), you better have the same paths in ~/.profile as you have in ~/.xsessionrc or else the terminal in tmux will show different or miss out various paths while echo $PATH.


"Blind faith to authority is the greatest enemy of truth."

Offline

#6 2020-03-23 07:43:38

Martin
Member
From: Stockholm, Sweden
Registered: 2015-10-01
Posts: 414
Website

Re: [SOLVED] .local/bin not adden to $PATH

damo wrote:
Martin wrote:

...
Me confused.

/Martin

So have a look at what .profile has to say...

#
# NOTE this file is not sourced by lightdm when logging in to X sessions.
# Use .xsessionrc for graphical sessions.

So edit .xsessionrc, NOT .profile, if you are using lightdm for login.

Aha, now things start to make sense.

/Martin


"Problems worthy of attack
prove their worth by hitting back."
Piet Hein

Offline

Board footer

Powered by FluxBB