updates
This commit is contained in:
parent
1820640e82
commit
7c5299d186
3 changed files with 14 additions and 2 deletions
|
|
@ -608,6 +608,10 @@ def _init_virtualenv(configuration, config, layout):
|
|||
|
||||
configuration.addbranch('virtualenv')
|
||||
|
||||
#
|
||||
# bin variable for where the virtualenvwrapper bin was installed
|
||||
configuration.virtualenv.bin = None
|
||||
configuration.virtualenv.bin = config['virtualenv'].get('bin')
|
||||
#
|
||||
# workon_home variable
|
||||
configuration.virtualenv.workon = config['virtualenv']['workon']
|
||||
|
|
|
|||
|
|
@ -95,7 +95,7 @@ def edit(remote_path, host_string=None):
|
|||
if sys.platform == "darwin":
|
||||
editor = "mvim"
|
||||
else:
|
||||
editor = "vim"
|
||||
editor = "nvim"
|
||||
|
||||
# if env.key_filename:
|
||||
# cmd_edit = "{editor} sftp://{user}@{host_string}/{remote_path}" \
|
||||
|
|
|
|||
|
|
@ -357,7 +357,15 @@ def virtualenv_source():
|
|||
|
||||
uses python yield command
|
||||
"""
|
||||
with prefix("source virtualenvwrapper.sh"):
|
||||
configuration = env.config
|
||||
venv_bin = configuration.virtualenv.bin
|
||||
|
||||
if venv_bin:
|
||||
venv_activate = f"source {venv_bin}/virtualenvwrapper.sh"
|
||||
else:
|
||||
venv_activate = "source virtualenvwrapper.sh"
|
||||
|
||||
with prefix(venv_activate):
|
||||
yield
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue