Skip to main content
adding suggested change
Source Link
Rmano
  • 32.1k
  • 16
  • 120
  • 187

I know that this question is quite old and answered, but I think I can add a bit of useful information.

In all the methods described above, the procedure that is suggested is:

  • launch a terminal
  • show the environment variables using env, or printenv or whatever

The problem of these solutions are that you are seeing the environment variables of the shell that is running into the terminal. You are not seeing the environment variables available to an application run, for example, directly by the graphic interface.

This is noticeable if, for example, you use your ~/.profile, or .bashrc, or .zshenv (depending on your shell) to modify the environment variables --- like the classic addition of directories to the path.

To see the environment variables available to the application started directly in the graphic environment, you can do the following (in Gnome Shell, I am sure there is an equivalent method in all the other DE):

  • press Alt-F2
  • run the command xterm -e bash --noprofile --norc

(Or, if you do not have xterm, gnome-terminal -- bash --noprofile --norc --- thanks to @Mike Nakis for the comment).

You now have a terminal with a shell that did not add any environment variables. You can use env here to list all your environment variables:

Example of the bare shell

Obviously the new shell will have the environment variables added by the system files, but that variables should be available (by inheritance) to all programs in the system anyway.

I am posting this because it's the fourth time I have to search this trick again, checking my .pam_environment file. So now I will find it faster (and in the process, I hope helping someone else...)

I know that this question is quite old and answered, but I think I can add a bit of useful information.

In all the methods described above, the procedure that is suggested is:

  • launch a terminal
  • show the environment variables using env, or printenv or whatever

The problem of these solutions are that you are seeing the environment variables of the shell that is running into the terminal. You are not seeing the environment variables available to an application run, for example, directly by the graphic interface.

This is noticeable if, for example, you use your ~/.profile, or .bashrc, or .zshenv (depending on your shell) to modify the environment variables --- like the classic addition of directories to the path.

To see the environment variables available to the application started directly in the graphic environment, you can do the following (in Gnome Shell, I am sure there is an equivalent method in all the other DE):

  • press Alt-F2
  • run the command xterm -e bash --noprofile --norc

You now have a terminal with a shell that did not add any environment variables. You can use env here to list all your environment variables:

Example of the bare shell

Obviously the new shell will have the environment variables added by the system files, but that variables should be available (by inheritance) to all programs in the system anyway.

I am posting this because it's the fourth time I have to search this trick again, checking my .pam_environment file. So now I will find it faster (and in the process, I hope helping someone else...)

I know that this question is quite old and answered, but I think I can add a bit of useful information.

In all the methods described above, the procedure that is suggested is:

  • launch a terminal
  • show the environment variables using env, or printenv or whatever

The problem of these solutions are that you are seeing the environment variables of the shell that is running into the terminal. You are not seeing the environment variables available to an application run, for example, directly by the graphic interface.

This is noticeable if, for example, you use your ~/.profile, or .bashrc, or .zshenv (depending on your shell) to modify the environment variables --- like the classic addition of directories to the path.

To see the environment variables available to the application started directly in the graphic environment, you can do the following (in Gnome Shell, I am sure there is an equivalent method in all the other DE):

  • press Alt-F2
  • run the command xterm -e bash --noprofile --norc

(Or, if you do not have xterm, gnome-terminal -- bash --noprofile --norc --- thanks to @Mike Nakis for the comment).

You now have a terminal with a shell that did not add any environment variables. You can use env here to list all your environment variables:

Example of the bare shell

Obviously the new shell will have the environment variables added by the system files, but that variables should be available (by inheritance) to all programs in the system anyway.

I am posting this because it's the fourth time I have to search this trick again, checking my .pam_environment file. So now I will find it faster (and in the process, I hope helping someone else...)

added 1 character in body
Source Link
Byte Commander
  • 108.2k
  • 49
  • 295
  • 431

I know that this question is quite old and answered, but I think I can add a bit of useful information.

In all the methods described above, the procedure that is suggested is:

  • lauchlaunch a terminal
  • show the environment variables using env, or printenv or whatever

The problem of these solutions are that you are seeing the environment variables of the shell that is running into the terminal. You are not seeing the environment variables available to an application run, for example, directly by the graphic interface.

This is noticeable if, for example, you use your ~/.profile, or .bashrc, or .zshenv (depending on your shell) to modify the environment variables --- like the classic addition of directories to the path.

To see the environment variables available to the application started directly in the graphic environment, you can do the following (in Gnome Shell, I am sure there is an equivalent method in all the other DE):

  • press Alt-F2
  • run the command xterm -e bash --noprofile --norc

You now have a terminal with a shell that did not add any environment variables. You can use env here to list all your environment variables:

Example of the bare shell

Obviously the new shell will have the environment variables added by the system files, but that variables should be available (by inheritance) to all programs in the system anyway.

I am posting this because it's the fourth time I have to search this trick again, checking my .pam_environment file. So now I will find it faster (and in the process, I hope helping someone else...)

I know that this question is quite old and answered, but I think I can add a bit of useful information.

In all the methods described above, the procedure that is suggested is:

  • lauch a terminal
  • show the environment variables using env, or printenv or whatever

The problem of these solutions are that you are seeing the environment variables of the shell that is running into the terminal. You are not seeing the environment variables available to an application run, for example, directly by the graphic interface.

This is noticeable if, for example, you use your ~/.profile, or .bashrc, or .zshenv (depending on your shell) to modify the environment variables --- like the classic addition of directories to the path.

To see the environment variables available to the application started directly in the graphic environment, you can do the following (in Gnome Shell, I am sure there is an equivalent method in all the other DE):

  • press Alt-F2
  • run the command xterm -e bash --noprofile --norc

You now have a terminal with a shell that did not add any environment variables. You can use env here to list all your environment variables:

Example of the bare shell

Obviously the new shell will have the environment variables added by the system files, but that variables should be available (by inheritance) to all programs in the system anyway.

I am posting this because it's the fourth time I have to search this trick again, checking my .pam_environment file. So now I will find it faster (and in the process, I hope helping someone else...)

I know that this question is quite old and answered, but I think I can add a bit of useful information.

In all the methods described above, the procedure that is suggested is:

  • launch a terminal
  • show the environment variables using env, or printenv or whatever

The problem of these solutions are that you are seeing the environment variables of the shell that is running into the terminal. You are not seeing the environment variables available to an application run, for example, directly by the graphic interface.

This is noticeable if, for example, you use your ~/.profile, or .bashrc, or .zshenv (depending on your shell) to modify the environment variables --- like the classic addition of directories to the path.

To see the environment variables available to the application started directly in the graphic environment, you can do the following (in Gnome Shell, I am sure there is an equivalent method in all the other DE):

  • press Alt-F2
  • run the command xterm -e bash --noprofile --norc

You now have a terminal with a shell that did not add any environment variables. You can use env here to list all your environment variables:

Example of the bare shell

Obviously the new shell will have the environment variables added by the system files, but that variables should be available (by inheritance) to all programs in the system anyway.

I am posting this because it's the fourth time I have to search this trick again, checking my .pam_environment file. So now I will find it faster (and in the process, I hope helping someone else...)

typo catch
Source Link
Rmano
  • 32.1k
  • 16
  • 120
  • 187

I know that this question is quite old and answered, but I think I can add a bit of useful information.

In all the methods described above, the procedure that is suggested is:

  • lauch a terminal
  • show the environment variables using env, or printenv or whatever

The problem of these solutions are that you are seeing the environment variables of the shell that is running into the terminal. You are not seeing the environment variables available to an application run, for example, directly by the graphic interface.

This is noticeable if, for example, you use your ~/.profile, or .bashrc, or .zshenv (depending on your shell) to modify the environment variables --- like the classic addition of directories to the path.

To see the environment variables available to the application started directly in the graphic environment, you can do the following (in Gnome Shell, I am sure there is an equivalent method in all the other DE):

  • press Alt-F2
  • run the command xterm -e bash --noprofile --norc

You now have a terminal with a shell that did not add any environment variables. You can use env here to list all your environment variables:

Example of the bare shell

Obviously the new shell will have the environment variables added by the system filefiles, but that variables should be available (by inheritance) to all programs in the system anyway.

I am posting this because it's the fourth time I have to search this trick again, checking my .pam_environment file. So now I will find it faster (and in the process, I hope helping someone else...)

I know that this question is quite old and answered, but I think I can add a bit of useful information.

In all the methods described above, the procedure that is suggested is:

  • lauch a terminal
  • show the environment variables using env, or printenv or whatever

The problem of these solutions are that you are seeing the environment variables of the shell that is running into the terminal. You are not seeing the environment variables available to an application run, for example, directly by the graphic interface.

This is noticeable if, for example, you use your ~/.profile, or .bashrc, or .zshenv (depending on your shell) to modify the environment variables --- like the classic addition of directories to the path.

To see the environment variables available to the application started directly in the graphic environment, you can do the following (in Gnome Shell, I am sure there is an equivalent method in all the other DE):

  • press Alt-F2
  • run the command xterm -e bash --noprofile --norc

You now have a terminal with a shell that did not add any environment variables. You can use env here to list all your environment variables:

Example of the bare shell

Obviously the new shell will have the environment variables added by the system file, but that variables should be available (by inheritance) to all programs in the system anyway.

I am posting this because it's the fourth time I have to search this trick again, checking my .pam_environment file. So now I will find it faster (and in the process, I hope helping someone else...)

I know that this question is quite old and answered, but I think I can add a bit of useful information.

In all the methods described above, the procedure that is suggested is:

  • lauch a terminal
  • show the environment variables using env, or printenv or whatever

The problem of these solutions are that you are seeing the environment variables of the shell that is running into the terminal. You are not seeing the environment variables available to an application run, for example, directly by the graphic interface.

This is noticeable if, for example, you use your ~/.profile, or .bashrc, or .zshenv (depending on your shell) to modify the environment variables --- like the classic addition of directories to the path.

To see the environment variables available to the application started directly in the graphic environment, you can do the following (in Gnome Shell, I am sure there is an equivalent method in all the other DE):

  • press Alt-F2
  • run the command xterm -e bash --noprofile --norc

You now have a terminal with a shell that did not add any environment variables. You can use env here to list all your environment variables:

Example of the bare shell

Obviously the new shell will have the environment variables added by the system files, but that variables should be available (by inheritance) to all programs in the system anyway.

I am posting this because it's the fourth time I have to search this trick again, checking my .pam_environment file. So now I will find it faster (and in the process, I hope helping someone else...)

corrected typos and formatting
Source Link
Rmano
  • 32.1k
  • 16
  • 120
  • 187
Loading
Source Link
Rmano
  • 32.1k
  • 16
  • 120
  • 187
Loading