public function isUpToDate(): bool
    {
        if (! $this->isTracking()) {
            throw new GitException(
                'Error: HEAD does not have a remote tracking branch. Cannot check if it is up-to-date.'
            );
        }

        $mergeBase = $this->run('merge-base', ['@', '@{u}']);
        $remoteSha = $this->run('rev-parse', ['@{u}']);
        return $mergeBase === $remoteSha;
    }
public function isUpToDate(): bool
    {
        if (! $this->isTracking()) {
            throw new GitException(
                'Error: HEAD does not have a remote tracking branch. Cannot check if it is up-to-date.'
            );
        }

        $mergeBase = $this->run('merge-base', ['@', '@{u}']);
        $remoteSha = $this->run('rev-parse', ['@{u}']);
        return $mergeBase === $remoteSha;
    }
public function isUpToDate ( ) : bool { if ( ! $ this -> isTracking ( ) ) { throw new GitException ( 'Error: HEAD does not have a remote tracking branch. Cannot check if it is up-to-date.' ) ; } $ mergeBase = $ this -> run ( 'merge-base' , [ '@' , '@{u}' ] ) ; $ remoteSha = $ this -> run ( 'rev-parse' , [ '@{u}' ] ) ; return $ mergeBase === $ remoteSha ; }
Returns whether HEAD is up-to-date with its remote tracking branch.
Returns whether HEAD is up - to - date with its remote tracking branch .