Velvet Star Monitor

Standout celebrity highlights with iconic style.

general

How to permanently set an environment variable [duplicate]

Writer Matthew Barrera

I am completely new to Ubuntu, and I would permanently set an environment variable. I have read here that I have to set ~/.profile, but I don't know how to apply it. In my case I would permanently set export PATH="/home/name/anaconda/bin:$PATH", how could I do?

4

1 Answer

  • Open a terminal window with Ctrl+Alt+T.
  • Open the file for editing with

    gedit ~/.profile
  • Add the command to the bottom of the file.

  • Save and close gedit.

  • Log out and log in again.

12