Adding directories to PATH in Ubuntu Visual Studio Code

I’m setting up vsc on Ubuntu right now, and after I installed django, I saw these warnings:

WARNING: The script sqlformat is installed in ‘/home/spha/.local/bin’ which is not on PATH.
Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location.
WARNING: The script django-admin is installed in ‘/home/spha/.local/bin’ which is not on PATH.
Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location.

I am not too familiar with PATH on linux, do you know where or how I can add these directories to PATH?

I have done this:

$ echo $PATH
/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin

sudo cp -R /home/spha/.local /usr/local/bin

source /home/spha/.bashrc

The standard practice is to add additional directories to your path in your .bashrc file.

For example, if you wanted to add .local to your path, you could add the following line:
export PATH=$PATH:/home/spha/.local/bin

1 Like