How to set an environment variable in bash?
The syntax in bash for setting an environment variable is as follows.
Note that there is no space among the variable, the equals sign (“=”) and the value. If the value has spaces, the value should be put in quotes.
To check it:
To make the variable settings effect for each bash shell, put the exporting command to your
~/.bashrc, the individual per-interactive-shell startup file.