Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion rsconnect/bundle.py
Original file line number Diff line number Diff line change
Expand Up @@ -815,8 +815,13 @@ def create_glob_set(directory, excludes):


def is_environment_dir(directory):
"""Detect whether `directory` is a virtualenv"""

# A virtualenv will have Python at ./bin/python
python_path = join(directory, "bin", "python")
return exists(python_path)
# But on Windows, it's at Scripts\Python.exe
win_path = join(directory, "Scripts", "Python.exe")
return exists(python_path) or exists(win_path)


def list_environment_dirs(directory):
Expand Down