this post was submitted on 05 Dec 2023
7 points (100.0% liked)

Debian operating system

2718 readers
1 users here now

Debian is a free operating system (OS) for your computer. An operating system is the set of basic programs and utilities that make your computer run. Debian provides more than a pure OS: it comes with over 59000 packages, precompiled software bundled up in a nice format for easy installation on your machine.

founded 4 years ago
MODERATORS
 

I have suddenly found that /usr/games has disappeared off my path. Not only that but my normal otherwise but sudo enabled user seems to have a superuser's path?

rhudson@adam:~$ echo $PATH /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin

rhudson@adam:~$ id -u 1000

What would have changed suddenly? It was not like this yesterday. kpat is in /usr/games and I was able to launch it from task manager yesterday, but not today.

I have rebooted twice so far. I can run kpat by opening it from Dolphin.

I don't want to have to re-install : ^ (

you are viewing a single comment's thread
view the rest of the comments
[–] I_Am_Jacks_____@lemmings.world 2 points 11 months ago (6 children)

Check your ~/.bash_profile, ~/.bashrc, and ~/.profile files. See if they were modified. You can add those paths (~/bin, /usr/games) to one of those files: export PATH=$PATH:~/bin:/usr/games

[–] waspentalive@lemmy.ml 1 points 11 months ago (1 children)

I have included this line in my .bash_profile:

export PATH="$HOME/bin:/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games"

In the very last line.

My PATH still looks like this:

rhudson@adam:~$ echo $PATH /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin

What could be changing my path after .bash_profile gets its say?

I am also adding it now to the last line of .bashrc

[–] waspentalive@lemmy.ml 1 points 11 months ago (1 children)

I have rebooted and now my path seems correct:

rhudson@adam:~$ echo $PATH /home/rhudson/bin:/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games

I can type "kpat" at the command line and it launches.

But when I click the icon in the task manager it still says it can't find the program 'kpat'

[–] I_Am_Jacks_____@lemmings.world 1 points 11 months ago (1 children)

Depending on how you're starting X (assuming X and not Wayland), you could add a line to your ~/.xprofile (or .xsession or .xinitrc) with ". ~/.bashrc" to make sure the path gets set before launching X.

[–] waspentalive@lemmy.ml 1 points 11 months ago (2 children)

The issue shows up under Wayland, not X. With X everything is working ok. I have yet to try a different Task Manager under Wayland though.

[–] I_Am_Jacks_____@lemmings.world 1 points 11 months ago

So I would look into how to make sure Wayland apps inherit your ~/.bashrc settings

[–] waspentalive@lemmy.ml 1 points 11 months ago

I took a moment to swich back to wayland, and tried "Task Manager" (I was using "Icons only Task Manager") both are showing this issue which is resolved by switching back to X.

load more comments (4 replies)