-1

I installed mamba yesterday via conda install -n base -c conda-forge mamba. But after installing it , my terminal is still saying zsh: command not found mamba.

What do I do?

I did mamba env create -f environment.yml. And was expecting to use mamba for package management.

  • Does this answer your question? [in mac always getting zsh: command not found:](https://stackoverflow.com/questions/18428374/in-mac-always-getting-zsh-command-not-found) – wovano Nov 06 '22 at 14:38
  • 1
    Please clarify your specific problem or provide additional details to highlight exactly what you need. As it's currently written, it's hard to tell exactly what you're asking. – Community Nov 06 '22 at 14:58
  • Your headline seems to indicate you where trying to execute a command `conda mamba`. Mamba is not an additional conda-command, but a replacement. So your command will start with `mamba`, not `conda`. Please post your exact commands you where using together with the resulting errormessage. – maddes8cht Mar 11 '23 at 10:26

2 Answers2

0

zsh uses the $PATH environment variable to find ncommands that you issue when you don't include a filepath in command. There are exceptions, such as built-ins and aliases and other stuff, but that's not important right now. And so, when you type the literal command mamba at the command line, each directory in the $PATH variable will be searched for an executable mamba file; the first one found will be executed.

Perhaps, after your install, the mamba file was created in a directory not found in your $PATH. Consider looking for the file mamba and then adding the directory to your $PATH.

find / -name mamba 2>/dev/null

The above command searches your entire filesystem for the mamba file. Errors that it reports will be ignored 2>/dev/null. I've done this because find will complain about a lot of directories you don't have access to. Anyway, if find tells you where the mamba file is, add mamba's directory to your PATH.

export PATH=$PATH:<directory-of-mamba>

It will help if you add the above line to your .zshrc as well so any new terminal sessions will also have the PATH set properly.

Mark
  • 4,249
  • 1
  • 18
  • 27
  • Looks like mamba isn't working on Mac M1 chip. I used micromamba instead and it worked. But thanks! The issue on github: https://github.com/mamba-org/mamba/issues/1826 – Javkhlan Enkhbold Nov 06 '22 at 19:30
0

Your headline seems to indicate you where trying to execute a command

conda mamba

Mamba is not an additional conda-command, but a replacement. So your command will start with mamba, not conda.

So instead of

conda update conda
conda update --all

you will do

mamba update conda
mamba update --all
maddes8cht
  • 569
  • 3
  • 16