diff options
Diffstat (limited to '__init__.py')
-rw-r--r-- | __init__.py | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/__init__.py b/__init__.py index e2971fd..5b0949c 100644 --- a/__init__.py +++ b/__init__.py @@ -32,10 +32,9 @@ def new_mod_install(mod_names): "--trusted-host", "pypi.org", "-U", "--force-reinstall", "--only-binary", ":all:"] - # check if pip is available - pip = None - try: # import the pip module - pip = importlib.import_module("pip") + # check if the pip module is available + try: + importlib.import_module("pip") except: # install pip subprocess.run([py_bin, "-B", "-m", "ensurepip"]) subprocess.run(pip_install + pip_modules) |