def run(self, cmd, cwd=os.curdir):
        """Run a command with :class:`~subprocess.Popen` in the context of the virtualenv

        :param cmd: A command to run in the virtual environment
        :type cmd: str or list
        :param str cwd: The working directory in which to execute the command, defaults to :data:`os.curdir`
        :return: A finished command object
        :rtype: :class:`~subprocess.Popen`
        """

        c = None
        with self.activated():
            script = vistir.cmdparse.Script.parse(cmd)
            c = vistir.misc.run(script._parts, return_object=True, nospin=True, cwd=cwd)
        return c
def run ( self , cmd , cwd = os . curdir ) : c = None with self . activated ( ) : script = vistir . cmdparse . Script . parse ( cmd ) c = vistir . misc . run ( script . _parts , return_object = True , nospin = True , cwd = cwd ) return c
Run a command with :class:`~subprocess.Popen` in the context of the virtualenv

        :param cmd: A command to run in the virtual environment
        :type cmd: str or list
        :param str cwd: The working directory in which to execute the command, defaults to :data:`os.curdir`
        :return: A finished command object
        :rtype: :class:`~subprocess.Popen`