public function getTotalCommits($file = null)
    {
        if (defined('PHP_WINDOWS_VERSION_BUILD')) {
            $command = "rev-list --count --all $file";
        } else {
            $command = "rev-list --all $file | wc -l";
        }

        $commits = $this->getClient()->run($this, $command);

        return trim($commits);
    }
public function getTotalCommits($file = null)
    {
        if (defined('PHP_WINDOWS_VERSION_BUILD')) {
            $command = "rev-list --count --all $file";
        } else {
            $command = "rev-list --all $file | wc -l";
        }

        $commits = $this->getClient()->run($this, $command);

        return trim($commits);
    }
public function getTotalCommits ( $ file = null ) { if ( defined ( 'PHP_WINDOWS_VERSION_BUILD' ) ) { $ command = "rev-list --count --all $file" ; } else { $ command = "rev-list --all $file | wc -l" ; } $ commits = $ this -> getClient ( ) -> run ( $ this , $ command ) ; return trim ( $ commits ) ; }
Show the amount of commits on the repository.

@return int Total number of commits
Show the amount of commits on the repository .