From 50b46e3ee7929f812cf90f8c50e856cac60f1d24 Mon Sep 17 00:00:00 2001 From: Aaron LI Date: Wed, 18 Jul 2018 21:42:04 +0800 Subject: profile: Support miniconda3/anaconda3 --- _profile | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to '_profile') diff --git a/_profile b/_profile index 7e69342..f410b6b 100644 --- a/_profile +++ b/_profile @@ -53,6 +53,17 @@ _running() { if [ -d "${HOME}/.npm-packages/bin" ]; then _path_prepend "${HOME}/.npm-packages/bin" fi +# Miniconda/Anaconda +if [ -d "${HOME}/miniconda3/bin" ]; then + _CONDA_DIR="${HOME}/miniconda3" +elif [ -d "${HOME}/anaconda3/bin" ]; then + _CONDA_DIR="${HOME}/anaconda3" +fi +if [ -n "${_CONDA_DIR}" ]; then + _path_prepend "${_CONDA_DIR}/bin" + . "${_CONDA_DIR}/etc/profile.d/conda.sh" + unset _CONDA_DIR +fi # Locally installed programs (e.g., Python) if [ -d "${HOME}/.local/bin" ]; then _path_prepend "${HOME}/.local/bin" -- cgit v1.2.2