public function getInfo($path = '.')
    {
        if(!$this->svnEnabled)
            return false;

        $user = escapeshellarg($this->svnUsername);
        $pw = escapeshellarg($this->svnPassword);

        $creds = !empty($this->svnUsername) && !empty($this->svnPassword) ? "--username {$user} --password {$pw}" : "";

        $version = trim(shell_exec("svn info {$creds} ".PATH_ROOT.'/'.$path));
        $this->Logger->debug($version);
        if(empty($version))
            return false;

        $status = trim(shell_exec("svn log {$creds} -r HEAD ".PATH_ROOT.'/'.$path));
        $this->Logger->debug($status);

        $data = array();
        $lines = explode("\n", $version);
        foreach($lines as $line) {
            $ld = explode(": ",$line,  2);
            if(count($ld) == 2)
            {
                list($name, $value) = $ld;
                $name = str_replace(' ', '', $name);
                if($name == 'LastChangedDate')
                    $value = substr($value, 0, strpos($value,'('));
                $data[$name] = $value;
            }
        }

        if(!empty($status))
        {
            $lines = explode("\n", $status);
            if(count($lines) <= 1)
                return false;

            $line2 = $lines[1];
            $logData = explode(' | ', $line2);


            $crevision = ltrim($logData[0], 'r');
            $cuser = $logData[1];
            $cdate = substr($logData[2], 0, strpos($logData[2],'('));

            $data['LatestRevision'] = $crevision;
            $data['LatestChangedDate'] = $cdate;
            $data['LatestChangedAuthor'] = $cuser;
        }

        return $data;
    }
public function getInfo($path = '.')
    {
        if(!$this->svnEnabled)
            return false;

        $user = escapeshellarg($this->svnUsername);
        $pw = escapeshellarg($this->svnPassword);

        $creds = !empty($this->svnUsername) && !empty($this->svnPassword) ? "--username {$user} --password {$pw}" : "";

        $version = trim(shell_exec("svn info {$creds} ".PATH_ROOT.'/'.$path));
        $this->Logger->debug($version);
        if(empty($version))
            return false;

        $status = trim(shell_exec("svn log {$creds} -r HEAD ".PATH_ROOT.'/'.$path));
        $this->Logger->debug($status);

        $data = array();
        $lines = explode("\n", $version);
        foreach($lines as $line) {
            $ld = explode(": ",$line,  2);
            if(count($ld) == 2)
            {
                list($name, $value) = $ld;
                $name = str_replace(' ', '', $name);
                if($name == 'LastChangedDate')
                    $value = substr($value, 0, strpos($value,'('));
                $data[$name] = $value;
            }
        }

        if(!empty($status))
        {
            $lines = explode("\n", $status);
            if(count($lines) <= 1)
                return false;

            $line2 = $lines[1];
            $logData = explode(' | ', $line2);


            $crevision = ltrim($logData[0], 'r');
            $cuser = $logData[1];
            $cdate = substr($logData[2], 0, strpos($logData[2],'('));

            $data['LatestRevision'] = $crevision;
            $data['LatestChangedDate'] = $cdate;
            $data['LatestChangedAuthor'] = $cuser;
        }

        return $data;
    }
public function getInfo ( $ path = '.' ) { if ( ! $ this -> svnEnabled ) return false ; $ user = escapeshellarg ( $ this -> svnUsername ) ; $ pw = escapeshellarg ( $ this -> svnPassword ) ; $ creds = ! empty ( $ this -> svnUsername ) && ! empty ( $ this -> svnPassword ) ? "--username {$user} --password {$pw}" : "" ; $ version = trim ( shell_exec ( "svn info {$creds} " . PATH_ROOT . '/' . $ path ) ) ; $ this -> Logger -> debug ( $ version ) ; if ( empty ( $ version ) ) return false ; $ status = trim ( shell_exec ( "svn log {$creds} -r HEAD " . PATH_ROOT . '/' . $ path ) ) ; $ this -> Logger -> debug ( $ status ) ; $ data = array ( ) ; $ lines = explode ( "\n" , $ version ) ; foreach ( $ lines as $ line ) { $ ld = explode ( ": " , $ line , 2 ) ; if ( count ( $ ld ) == 2 ) { list ( $ name , $ value ) = $ ld ; $ name = str_replace ( ' ' , '' , $ name ) ; if ( $ name == 'LastChangedDate' ) $ value = substr ( $ value , 0 , strpos ( $ value , '(' ) ) ; $ data [ $ name ] = $ value ; } } if ( ! empty ( $ status ) ) { $ lines = explode ( "\n" , $ status ) ; if ( count ( $ lines ) <= 1 ) return false ; $ line2 = $ lines [ 1 ] ; $ logData = explode ( ' | ' , $ line2 ) ; $ crevision = ltrim ( $ logData [ 0 ] , 'r' ) ; $ cuser = $ logData [ 1 ] ; $ cdate = substr ( $ logData [ 2 ] , 0 , strpos ( $ logData [ 2 ] , '(' ) ) ; $ data [ 'LatestRevision' ] = $ crevision ; $ data [ 'LatestChangedDate' ] = $ cdate ; $ data [ 'LatestChangedAuthor' ] = $ cuser ; } return $ data ; }
Performs an svn info on the provided path.
Returns an array of SVN commit data, or false on failure.

@param string $path
@return array|bool
Performs an svn info on the provided path . Returns an array of SVN commit data or false on failure .