Linux – How to delete an exported environment variable

environment-variableslinuxunset

Before installing gnuplot, I set the environment variable GNUPLOT_DRIVER_DIR = /home/gnuplot/build/src. During the installation, something went wrong.

I want to remove the GNUPLOT_DRIVER_DIR environment variable. How can I achieve it?

Best Answer

unset is the command you're looking for.

unset GNUPLOT_DRIVER_DIR