Installing in silent mode

Windows

Download the installer:

NOTE: The following instructions are for Miniconda. For Anaconda, substitute Anaconda for Miniconda in all of the commands.

To run the the Windows installer for Miniconda in silent mode, use the /S argument. The following optional arguments are supported:

  • /InstallationType=[JustMe|AllUsers]—Default is``JustMe``.
  • /AddToPath=[0|1]—Default is 1
  • /RegisterPython=[0|1]—Make this the system’s default Python. 0 indicates JustMe, which is the default. 1 indicates AllUsers.
  • /S—Install in silent mode.
  • /D=<installation path>—Destination installation path. Must be the last argument. Do not wrap in quotation marks. Required if you use /S.

All arguments are case-sensitive.

EXAMPLE: The following command installs Miniconda for the current user without registering Python as the system’s default:

start /wait "" Miniconda3-latest-Windows-x86_64.exe /InstallationType=JustMe /RegisterPython=0 /S /D=%UserProfile%\Miniconda3

Linux & macOS

NOTE: The following instructions are for Miniconda. For Anaconda, substitute anaconda for miniconda in all of the commands. Also, substitute the Anaconda installer for the Miniconda installer in the wget step.

To run the silent installation of Miniconda for macOS or Linux, specify the -b and -p arguments of the bash installer. The following arguments are supported:

  • -b—Batch mode with no PATH modifications to ~/.bashrc. Assumes that you agree to the license agreement. Does not edit the .bashrc or .bash_profile files.
  • -p—Installation prefix/path.
  • -f—Force installation even if prefix -p already exists.

EXAMPLE:

wget https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh -O ~/miniconda.sh
bash ~/miniconda.sh -b -p $HOME/miniconda
export PATH="$HOME/miniconda/bin:$PATH"

NOTE: This sets the PATH only for the current session, not permanently. Trying to use conda when conda is not in your PATH causes errors such as “command not found.”

In each new bash session, before using conda, set the PATH and run the activation scripts of your conda packages by running:

source $HOME/miniconda/bin/activate

NOTE: Replace $HOME/miniconda/bin/activate with the path to the activate script in your conda installation.

To set the PATH permanently, you can add a line to your .bashrc file. However, this makes it possible to use conda without running the activation scripts of your conda packages, which may produce errors.

EXAMPLE:

export PATH="$HOME/miniconda/bin:$PATH"