Linked Questions

4
votes
2answers
5k views

Setting path environment variable for desktop launchers [duplicate]

I set a custom $PATH in ~/.bashrc with PATH=$HOME/.bin:$PATH. When I launch the geany from the terminal it is able to find my custom build tools that are located in $HOME/.bin. When I launch Geany ...
1
vote
1answer
1k views

Terminal sometimes fails to find executables on local directory [duplicate]

I can open my terminal emulator via a keyboard shortcut or through the apps finder that executes the exo-open --launch TerminalEmulator command. My terminal starts and I can cd to any directory and ...
0
votes
1answer
468 views

What is the scope of environment variables defined in ~/.bashrc? [duplicate]

Considering that environment variables defined in a shell are available to the child processes of the shell. When we open a terminal, it reads .bashrc and executes its commands. That means the .bashrc ...
0
votes
1answer
873 views

How and where should I add a PATH? [duplicate]

I need to add a new directory to my PATH so that SublimeText can find it. I assume this should be added to either .bash_profile, .bashrc, or .profile. Which one should I add it to? .bash_profile ...
1
vote
1answer
463 views

Running a bash script on double click does not have all environment variables [duplicate]

I am running Debian. I have a jar file that I need to execute. A wrapper bash script does a java -jar MyProg.jar. The jar also calls some C code for which LD_LIBRARY_PATH needs to be set. I have set ...
0
votes
1answer
313 views

Fedora 7 server export in .bashrc not getting set [duplicate]

I'm trying to set the JAVA_HOME environment variable in my .bashrc but every time I log back in it gets unset again to its original value, below is my .bashrc file # .bashrc # User specific aliases ...
0
votes
0answers
110 views

Are .bashrc and .zshrc the wrong place for environment variables? [duplicate]

I have updated the question after an answer to a related question : see the later pragraphs. When I startup spacemacs I get the following warning: You appear to be setting environment variables ("...
0
votes
0answers
31 views

How to modify ENV in Solaris 10 [duplicate]

I wanted to edit the contents of environment when entering this "ENV" in terminal. I googled this but so far none of the solution offered works in my end. The closes solution that i got was to edit ...
1
vote
0answers
27 views

In which file should one put the PATH and LD_LIBRARY_PATH variables? [duplicate]

After having installed cuda drivers on Ubuntu 16.04, the program told me to make sure to have /usr/local/cuda-8.0 in the PATH variable and /usr/local/cuda-8.0/lib64 in the LD_LIBRARY_PATH variable. I ...
60
votes
3answers
77k views

How do I change the default text editor in the Debian (squeeze) distro

"Joe's own editor" does not come naturally to me. How do I change to using nano or vim? I've tried export EDITOR=nano but it doesn't seem to be respected. I'd like visudo to respect this as well.
54
votes
4answers
78k views

What is the difference between ~/.profile and ~/.bash_profile?

What is the difference between ~/.profile and ~/.bash_profile?
40
votes
3answers
46k views

using export in .bashrc

I have noticed in my .bashrc, that some lines have export in front, such as export HISTTIMEFORMAT="%b-%d %H:%M " ... export MYSQL_HISTFILE="/root/.mysql_history" whereas other have not, such as ...
31
votes
5answers
67k views

Why doesn't my ~/.bash_profile work?

I'm using Linux Mint. My login shell (cat /etc/passwd | grep myUserName) is bash. After I start my graphical desktop environment and run a terminal emulator from it, I can see that .bash_profile is ...
22
votes
6answers
57k views

How to add a function to .bash_profile/.profile/bashrc in shell?

I have a function which converts epoch time to date. Here is the definition date1(){ date -d @$1 } I'd like to be able to write: $ date1 xxxyyy Where xxxyyy is the parameter I pass into my ...
22
votes
5answers
54k views

Export an env variable to be available at all sub shells, and possible to be modified?

Suppose I have export MY_VAR=0 in ~/.bashrc. I have an opened gnome terminal, and in this terminal, I change $MY_VAR value to 200. So, if I do echo $MY_VAR in this terminal, 200 is shown. Now, I ...

15 30 50 per page