public function rootDiff(Commit $commit)
    {
        if (!$commit->isRoot()) {
            throw new \InvalidArgumentException('rootDiff method accepts only root commits');
        }
        $this->clearAll();
        $this->addCommandName(static::DIFF_TREE_COMMAND);
        $this->addCommandArgument('--cc');
        $this->addCommandArgument('--root');
        $this->addCommandArgument('--dst-prefix=DST/');
        $this->addCommandArgument('--src-prefix=SRC/');
        $this->addCommandSubject($commit);

        return $this->getCommand();
    }
public function rootDiff(Commit $commit)
    {
        if (!$commit->isRoot()) {
            throw new \InvalidArgumentException('rootDiff method accepts only root commits');
        }
        $this->clearAll();
        $this->addCommandName(static::DIFF_TREE_COMMAND);
        $this->addCommandArgument('--cc');
        $this->addCommandArgument('--root');
        $this->addCommandArgument('--dst-prefix=DST/');
        $this->addCommandArgument('--src-prefix=SRC/');
        $this->addCommandSubject($commit);

        return $this->getCommand();
    }
public function rootDiff ( Commit $ commit ) { if ( ! $ commit -> isRoot ( ) ) { throw new \ InvalidArgumentException ( 'rootDiff method accepts only root commits' ) ; } $ this -> clearAll ( ) ; $ this -> addCommandName ( static :: DIFF_TREE_COMMAND ) ; $ this -> addCommandArgument ( '--cc' ) ; $ this -> addCommandArgument ( '--root' ) ; $ this -> addCommandArgument ( '--dst-prefix=DST/' ) ; $ this -> addCommandArgument ( '--src-prefix=SRC/' ) ; $ this -> addCommandSubject ( $ commit ) ; return $ this -> getCommand ( ) ; }
get a diff of a root commit with the empty repository

@param \GitElephant\Objects\Commit $commit the root commit object

@throws \RuntimeException
@throws \InvalidArgumentException
@return string
get a diff of a root commit with the empty repository