public function cloneRepository($remote)
    {
        $fileSystem = new Filesystem();
        $fileSystem->mkdir($this->directory);

        if ($fileSystem->exists($this->directory.DIRECTORY_SEPARATOR.'.git')) {
            throw new \RuntimeException(sprintf('"%s" already is a git repository.', $this->directory));
        }

        return $this->executeCmd(sprintf(
            self::CMD_GITCLONE,
            $remote,
            $this->directory
        ));
    }