diff --git a/001-Jupyter/Create_JupyterKernel_pyenv.ipynb b/001-Jupyter/Create_JupyterKernel_pyenv.ipynb index 2a26cff4592bd70d7803ec08c966742b7806fb6c..3f775bc9def51aa308395ea27ba594b959231a7d 100644 --- a/001-Jupyter/Create_JupyterKernel_pyenv.ipynb +++ b/001-Jupyter/Create_JupyterKernel_pyenv.ipynb @@ -37,18 +37,12 @@ "## Building your own Jupyter pyenv-kernel is a four-step process\n", "\n", "1. **[Download/Install pyenv](#install)**: To start from scratch, and run the full installation.\n", - "2. **[Create and setup environment](#environment)**: To create an(other) environment in an existing pyenv setup.\n", - "3. **[Create/Edit launch script for the Jupyter kernel](#kernel)**: To setup an environment to be run via Jupyter.\n", - "4. **[Create/Edit Jupyter kernel configuration](#json)**: To attach your user to an existing environment via Jupyter. " - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "If `pyenv` is already installed, start at 2.\n", - "If the environment already exists, start at 3.\n", - "If the kernel launch script was already created (e.g., by some other user in the project), start at 4." + "2. **[Create and setup environment](#environment)**: To create an(other) environment in an existing pyenv setup. \n", + "If `pyenv` is already installed, start here.\n", + "3. **[Create/Edit launch script for the Jupyter kernel](#kernel)**: To setup an environment to be run via Jupyter. \n", + "If the environment already exists, start here.\n", + "4. **[Create/Edit Jupyter kernel configuration](#json)**: To attach your user to an existing environment via Jupyter. \n", + "If the kernel launch script was already created (e.g., by some other user in the project), start here." ] }, { @@ -79,7 +73,7 @@ "metadata": {}, "outputs": [], "source": [ - "export PYENV_ROOT=${PROJECT_<projectid>}/.pyenv\n", + "export PYENV_ROOT=${PROJECT_<projectid>}/${USER}/.pyenv\n", "export PATH=\"$PYENV_ROOT/bin:$PATH\"" ] }, @@ -99,13 +93,6 @@ "export PYENV_ENV=my_env" ] }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "These lines can be added to `~/.bash_profile` (and then `source ~/.bash_profile`) to automatically set the PATH in case of restarting the shell." - ] - }, { "cell_type": "markdown", "metadata": {}, @@ -158,7 +145,7 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "Since it is necessary to activate the environment to install the required modules, the following commands should be added to `~/.bash_profile` to activate pyenv and the virtual environments:" + "Activate pyenv and the virtual environments by running:" ] }, { @@ -172,22 +159,6 @@ "eval \"$(pyenv virtualenv-init -)\"" ] }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "And activate the lines" - ] - }, - { - "cell_type": "code", - "execution_count": null, - "metadata": {}, - "outputs": [], - "source": [ - "source ~/.bash_profile" - ] - }, { "cell_type": "markdown", "metadata": {}, @@ -373,7 +344,7 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "The following steps describe how to create and configure the launch script of a new Jupyter kernel using a pyenv environment. If the environment was created in the $PROJECT folder, many users of the project can follow these steps to create the kernel. The steps assume the variables described in the **[Settings section](#settings)** are set up. Here, they don't need to be set in `~/.bash_profile` or `~/.bashrc`." + "The following steps describe how to create and configure the launch script of a new Jupyter kernel using a pyenv environment. If the environment was created in the $PROJECT folder, many users of the project can follow these steps to create the kernel. The steps assume the variables described in the **[Settings section](#settings)** are set up." ] }, { @@ -406,13 +377,6 @@ "exec python -m ipykernel $@' > ${PYENV_ROOT}/versions/${PYENV_ENV}/kernel.sh" ] }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "Note: the `export` and `eval` lines are repeated here as they are not required to be in `~/.bash_profile` on these steps." - ] - }, { "cell_type": "markdown", "metadata": {},