Skip to content
This repository has been archived by the owner on Jul 4, 2020. It is now read-only.

Commit

Permalink
don't use pip --user because that doesn't work as expected in a virtu…
Browse files Browse the repository at this point in the history
…alenv
  • Loading branch information
irmen committed Jul 26, 2017
1 parent 29b6b14 commit 3787483
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions tale/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,12 +64,14 @@ def _check_required_libraries():
all_good = False
if not all_good:
print("\nInstall this/these and try again. Try using your package manager (on Linux) or try executing the following command:")
print(' pip install --user "appdirs" "smartypants>={spv}" "colorama>={cv}" "serpent>={sv}"'
print(' pip install "appdirs" "smartypants>={spv}" "colorama>={cv}" "serpent>={sv}"'
.format(spv=smartypants_version_required, cv=colorama_version_required, sv=serpent_version_required))
print("(you may have to add the --user option if you have insufficient privileges)")
choice = input("\nDo you want to attempt to install them (using pip) right now (y/n)? ")
if choice == 'y':
import pip
statuscode = pip.main(["install", "--user", "appdirs", "smartypants>=" + str(smartypants_version_required),
# we don't use "--user" here because then it won't work when using a virtualenv.
statuscode = pip.main(["install", "appdirs", "smartypants>=" + str(smartypants_version_required),
"colorama>=" + str(colorama_version_required), "serpent>=" + str(serpent_version_required)])
if statuscode:
print("\n\nInstallation failed.\n")
Expand Down

0 comments on commit 3787483

Please sign in to comment.