9

Basically, this is a duplicate of this question. Reproducing the proposed behavior with spacemacs, I changed my user-init to: (defun dotspacemacs/user-init () (setenv "WORKON_HOME" "/home/<username>/.local/bin/anaconda3/envs") ) After reloading my .spacemacs file with SPC f e R, I'm immediately able to use , V w and select environments from my ...


2

You can use conda.el to manage your conda environments within python. After install and setup, do M-x conda activate python2


1

Step 1: If you haven't already done so, go ahead and create a new conda environment. Let us say we want to create an anaconda environment with name py38 which uses python 3.8. Execute the following in an (Anaconda prompt) conda create --name py38 python=3.8 Note: You can get to an anaconda prompt by clicking on the windows button and then searching for ...


1

I managed to set up something close to my requirements above. Here it is, for people who may have my same needs. Let me stress that such requirements are very subjective, so the set-up below is not meant as a fit-all solution. It specifically addresses Windows users. The setup involves the python distribution and Emacs's configuration: Python distribution ...


1

I use pyvenv to activate/manage my virtual environments and have the following called from my init.el... (elpy-enable) (pyvenv-activate "~/.virtualenvs/dskit") I have installed virtualenvwrapper which resides in ~/.virtualenvs and creates the virtualenvs within there (e.g. dskit that is being activated). As you are using Conda change ~/.virtualenvs/dskit ...


1

Anaconda-mode is a minor-mode which has nothing to do with indentation AFAIK. So I assume that you actually mean python-mode. The second line in python-mode is (set (make-local-variable 'indent-tabs-mode) nil) which overrides the default value. So you must set indent-tabs-mode in python-mode-hook: (add-hook 'python-mode-hook (lambda () (setq indent-tabs-...


1

Referencing this issue from the elpy package, a solution to your problem may be adding the --simple-prompt and --pprint arguments to the python-shell-interpreter-args variable, like so: (setq python-shell-interpreter-args "--simple-prompt --pprint") The default prompt display for IPython doesn't play nicely with how the Emacs terminal displays it, which is ...


1

I just went through a similar ordeal trying to bind a key in ess-mode with spacemacs. Assuming you're using evil-mode, I think the following will work: (evil-define-key 'insert python-mode (kbd "M-r") 'replace-string)


1

I don't know anything about how Spacemacs works, but the attempts with global-set-key or evil-insert-state-map aren't supposed to work, because the local keymaps take precedence! I think it should work to set it in the anaconda-mode-map. So you can modify the my-python-mode-config function to call (define-key anaconda-mode-map (kbd "M-r") 'replace-string) ...


Only top voted, non community-wiki answers of a minimum length are eligible