Skip to content

Commit

Permalink
Correct csh syntax in activate_virtualenv
Browse files Browse the repository at this point in the history
In csh, the . operator executes a directory, which is the wrong
behaviour here. At best, when pipenv is installed system-wide
(preferably via the operating system package manager), the result
is a permission denied error from the shell.

As csh uses the source command, reflect that here.
  • Loading branch information
vishwin committed Feb 28, 2018
1 parent df2c9f1 commit f14eb19
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions pipenv/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -1218,6 +1218,7 @@ def activate_virtualenv(source=True):
# Support for csh shell.
if PIPENV_SHELL and 'csh' in PIPENV_SHELL:
suffix = '.csh'
command = 'source'

# Escape any spaces located within the virtualenv path to allow
# for proper activation.
Expand Down

0 comments on commit f14eb19

Please sign in to comment.