ubuntuanacondawindows-subsystem-for-linux

Complete removal of conda in WSL


I am a newbie in this WSL (even Linux command system in general) business.

I first installed my anaconda using the following tutorial : https://linuxize.com/post/how-to-install-anaconda-on-ubuntu-18-04/

but when they ask

Installation finished. Do you wish the installer to prepend the Anaconda3 install location to PATH in your /home/linuxize/.bashrc ? [yes|no]

I accidentally pressed enter, which means "no". Causing me unable to follow the next step ahead. Then I wanted to restart all over again. Would you guys know what I should do?

Previously I had a doubt that my C drive would be enough, then I tried to install the .sh file again via the WSL command line into another directory another drive.

I naively deleted the whole folder of those installations (in another drive) via the windows file explorer, attempting to restart all over again. Now I am not sure whether it is really gone or remained in other places. While installation in C drive can't be deleted, it is %LOCALAPPDATA%\Packages\CanonicalGroupLimited.UbuntuonWindows_79rhkp1fndgsc\LocalState\rootfs right?

I have tried rm -rf ~/anaconda3 command but as you can guess, it's done nothing.

Thank you


Solution

  • Open a terminal window, and then remove your entire Anaconda directory, which has a name such as anaconda2 or anaconda3, by entering rm -rf ~/anaconda3.

    Then you need to edit the .bashrc file with

    nano .bashrc