15.6.2. Environment Variables
If you installed into /usr/local/pgsql or some other location that is not searched for programs by default, you should add /usr/local/pgsql/bin (or whatever you set --bindir to in step 1) into yourPATH. Strictly speaking, this is not necessary, but it will make the use of PostgreSQL much more convenient.
To do this, add the following to your shell start-up file, such as ~/.bash_profile (or /etc/profile, if you want it to affect all users):
PATH=/usr/local/pgsql/bin:$PATH export PATH
If you are using csh or tcsh, then use this c