0

I have two python3.8 installed, and one is used when I have sudo rights in the terminal, the other one when I haven't:

There is a python3.8 installed (I think by software I use):

sudo which python3.8

/usr/bin/python3.8

and a python3.8 installed for spyder under

which python3.8

/home/myname/anaconda3/bin/python3.8

I need the anaconda3/bin/python3.8 for a project, but now I would like to install a package that I had to build myself to python3.8 and it took me days until I realized that sudo which python3.8 and which python3.8 are not the same. How can I install something with sudo to the anaconda/bin/python3.8?

Ian Abbott
  • 15,083
  • 19
  • 33
CST
  • 207
  • 1
  • 6
  • 1
    You can do the other way round by refer to this answer : [Use the default Python rather than the Anaconda installation when called from the terminal](https://stackoverflow.com/questions/24664435/use-the-default-python-rather-than-the-anaconda-installation-when-called-from-th) – Ray Jul 14 '21 at 14:42

1 Answers1

0

The code I was ment to run:

sudo python3.8 Packaging/setup.py install

I changed it to:

sudo /home/myname/anaconda3/bin/python3.8 Packaging/setup.py install 
CST
  • 207
  • 1
  • 6