Subversion Repositories oidplus

Rev

Rev 557 | Rev 567 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 557 Rev 558
Line 943... Line 943...
943
        public static function getInstallType() {
943
        public static function getInstallType() {
944
                $counter = 0;
944
                $counter = 0;
945
 
945
 
946
                if ($version_file_exists = file_exists(OIDplus::localpath().'oidplus_version.txt'))
946
                if ($version_file_exists = file_exists(OIDplus::localpath().'oidplus_version.txt'))
947
                        $counter++;
947
                        $counter++;
948
                        if ($svn_dir_exists = is_dir(OIDplus::localpath().'.svn'))
948
                        if ($svn_dir_exists = is_dir(OIDplus::localpath().'.svn') ||
-
 
949
                                              is_dir(OIDplus::localpath().'../.svn')) // in case we checked out the root instead of the "trunk"
949
                        $counter++;
950
                        $counter++;
950
                        if ($git_dir_exists = is_dir(OIDplus::localpath().'.git'))
951
                        if ($git_dir_exists = is_dir(OIDplus::localpath().'.git'))
951
                        $counter++;
952
                        $counter++;
952
 
953
 
953
                if ($counter === 0) {
954
                if ($counter === 0) {
Line 990... Line 991...
990
 
991
 
991
                if ($installType === 'svn-wc') {
992
                if ($installType === 'svn-wc') {
992
                        $ver = get_svn_revision(OIDplus::localpath());
993
                        $ver = get_svn_revision(OIDplus::localpath());
993
                        if ($ver)
994
                        if ($ver)
994
                                return ($cachedVersion = 'svn-'.$ver);
995
                                return ($cachedVersion = 'svn-'.$ver);
-
 
996
                        $ver = get_svn_revision(OIDplus::localpath().'../'); // in case we checked out the root instead of the "trunk"
-
 
997
                        if ($ver)
-
 
998
                                return ($cachedVersion = 'svn-'.$ver);
995
                }
999
                }
996
 
1000
 
997
                if ($installType === 'git-wc') {
1001
                if ($installType === 'git-wc') {
998
                        $ver = get_gitsvn_revision(OIDplus::localpath());
1002
                        $ver = get_gitsvn_revision(OIDplus::localpath());
999
                        if ($ver)
1003
                        if ($ver)