Ejemplo n.º 1
0
    def handle(self):
        from poetry.utils.env import EnvManager

        env = EnvManager(self.poetry).get()

        if self.option("path"):
            if not env.is_venv():
                return 1

            self.write(str(env.path))

            return

        self._display_complete_info(env)
Ejemplo n.º 2
0
    def handle(self):
        from poetry.utils.env import EnvManager

        poetry = self.poetry
        env = EnvManager(poetry.config).get(cwd=poetry.file.parent)

        if self.option("path"):
            if not env.is_venv():
                return 1

            self.write(str(env.path))

            return

        self._display_complete_info(env)