I'm trying to add /home/garrett/bin/libpy/ to my python path so I can import my own libraries, I would also prefer not to overwrite the default python path but rather append my own path to the default. When I try to echo $PYTHONPATH
or $PYTHONHOME
I get nothing and even if I were to set it on the command line it wouldn't remain after the next reboot. I don't know where the config file for this is. Here's what the man pages had to say.
PYTHONHOME
Change the location of the standard Python libraries. By default, the libraries are searched in ${prefix}/lib/python<version> and ${exec_prefix}/lib/python<version>, where ${prefix} and ${exec_prefix} are installa‐
tion-dependent directories, both defaulting to /usr/local. When $PYTHONHOME is set to a single directory, its value replaces both ${prefix} and ${exec_prefix}. To specify different values for these, set $PYTHONHOME
to ${prefix}:${exec_prefix}.
PYTHONPATH
Augments the default search path for module files. The format is the same as the shell's $PATH: one or more directory pathnames separated by colons. Non-existent directories are silently ignored. The default search
path is installation dependent, but generally begins with ${prefix}/lib/python<version> (see PYTHONHOME above). The default search path is always appended to $PYTHONPATH. If a script argument is given, the directory
containing the script is inserted in the path in front of $PYTHONPATH. The search path can be manipulated from within a Python program as the variable sys.path.