diff --git a/README.md b/README.md index 642e686..0867052 100644 --- a/README.md +++ b/README.md @@ -229,6 +229,7 @@ Xcode: launchimage Create Launch images for your xcode project icon Create Icons for your xcode project pip Install a pip dependency into the distribution + pip3 Install a pip dependency into the python 3 distribution ``` ## FAQ diff --git a/toolchain.py b/toolchain.py index af6113c..f85c364 100755 --- a/toolchain.py +++ b/toolchain.py @@ -1477,8 +1477,10 @@ Xcode: env = arch.get_env() print("env ({}): {}".format(arch, pformat(env))) + def pip3(self): + self.pip(pip_version="pip3") - def pip(self): + def pip(self, pip_version="pip"): ctx = Context() for recipe in Recipe.list_recipes(): key = "{}.build_all".format(recipe) @@ -1497,7 +1499,7 @@ Xcode: "PYTHONOPTIMIZE": "2", # "PIP_INSTALL_TARGET": ctx.site_packages_dir } - pip_path = sh.which("pip") + pip_path = sh.which(pip_version) pip_args = [] if len(sys.argv) > 2 and sys.argv[2] == "install": pip_args = ["--isolated", "--ignore-installed", "--prefix", ctx.python_prefix]