-
-
Save manisnesan/9e388a00d6326a1fa4ea1a1ec9460254 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
set -e | |
cd | |
case "$OSTYPE" in | |
darwin*) DOWNLOAD=https://repo.anaconda.com/miniconda/Miniconda3-latest-MacOSX-x86_64.sh ;; | |
linux*) DOWNLOAD=https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh ;; | |
*) echo "unknown: $OSTYPE" ;; | |
esac | |
case "$SHELL" in | |
/bin/zsh*) SHELL_NAME=zsh ;; | |
/bin/bash*) SHELL_NAME=bash ;; | |
*) echo "unknown: $SHELL" ;; | |
esac | |
cat << EOF > .condarc | |
channels: | |
- fastai | |
- pytorch | |
- defaults | |
channel_priority: strict | |
EOF | |
wget $DOWNLOAD | |
bash Miniconda3-latest*.sh -b | |
~/miniconda3/bin/conda init $SHELL_NAME | |
rm Miniconda3-latest*.sh | |
perl -n -e 'print if />>> conda/../<<< conda/' .bashrc > .condainit | |
perl -ni -e 'print unless />>> conda/../<<< conda/' .bashrc | |
echo source ~/.condainit >> .bashrc | |
source .condainit | |
conda install -y mamba |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment