Skip to content

How to activate a specific conda environment within the runner? #298

Open

Description

@mbilyanov

Hi,

When inside tmux, the new pane invoked by vim-dispatch will use a default conda environment. Anyone using vim-dispatch inside a conda environment? Is there a way to activate a specific conda environment in the process started by vim-dispatch?

I have tried to call conda inside the command being passed to Start and Dispatch but with no success.

:Start conda activate myEnv && bokeh serve --show my_app

But conda throws bunch of complaints about the shell not being compatible etc.

Any ideas?

Activity

  1. mbilyanov commented on May 22, 2020

    @mbilyanov
    Author

    I'm aware this might be a conda issue. Just wondering if someone attempted the similar thing I'm attempting. I tried this:

    tmux new-window -n:mywindow 'echo "__START__"; conda activate py37; echo "___END___"; sleep 5'

    And I can confirm this is producing the same issue.

    __START__
    
    CommandNotFoundError: Your shell has not been properly configured to use 'conda activate'.
    To initialize your shell, run
    
        $ conda init <SHELL_NAME>
    
    Currently supported shells are:
      - bash
      - fish
      - tcsh
      - xonsh
      - zsh
      - powershell
    
    See 'conda init --help' for more information and options.
    
    IMPORTANT: You may need to close and restart your shell after running 'conda init'.
    
    
    ___END___
    
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions