~ubuntu-branches/ubuntu/trusty/psychtoolbox-3/trusty-proposed

« back to all changes in this revision

Viewing changes to Psychtoolbox/PsychOneliners/GetSubversionPath.m

  • Committer: Package Import Robot
  • Author(s): Yaroslav Halchenko
  • Date: 2013-11-19 23:34:50 UTC
  • mfrom: (3.1.4 experimental)
  • Revision ID: package-import@ubuntu.com-20131119233450-f7nf92vb8qavjmk8
Tags: 3.0.11.20131017.dfsg1-3
Upload to unsable since fresh glew has arrived to sid!

Show diffs side-by-side

added added

removed removed

Lines of Context:
18
18
% History:
19
19
% 11/21/06 Written (MK).
20
20
% 01/19/09 Update to search in /bin and /usr/bin as well on OS/X.
 
21
% 03/10/13 Change search path order to match DownloadPsychtoolbox on OS/X (MK)
 
22
% 04/24/13 Move check for /opt/subversion/bin/svn first. Nicolas Cottaris in
 
23
%          my lab says this fixes a problem that arose when he installed SVN 1.7.9. (DHB)
21
24
 
22
25
% Check for alternative install location of Subversion:
23
26
if IsWin
40
43
        % Currently, we only know how to check this for Mac OSX.
41
44
        if IsOSX
42
45
                svnpath = '';
43
 
                
44
 
                if isempty(svnpath) & exist('/opt/subversion/bin/svn', 'file') %#ok<AND2>
 
46
                     
 
47
                if isempty(svnpath) && exist('/opt/subversion/bin/svn', 'file')
45
48
                        svnpath = '/opt/subversion/bin/';
 
49
        end
 
50
        
 
51
                if isempty(svnpath) && exist('/usr/bin/svn','file')
 
52
                        svnpath='/usr/bin/';
46
53
                end
47
54
 
48
 
                if isempty(svnpath) & exist('/usr/local/bin/svn','file') %#ok<AND2>
 
55
                if isempty(svnpath) && exist('/usr/local/bin/svn','file')
49
56
                        svnpath='/usr/local/bin/';
50
57
                end
51
58
 
52
 
                if isempty(svnpath) & exist('/usr/bin/svn','file') %#ok<AND2>
53
 
                        svnpath='/usr/bin/';
54
 
                end
55
 
 
56
 
                if isempty(svnpath) & exist('/bin/svn','file') %#ok<AND2>
 
59
                if isempty(svnpath) && exist('/bin/svn','file')
57
60
                        svnpath='/bin/';
58
61
                end
59
62
 
60
 
                if isempty(svnpath) & exist('/opt/local/bin/svn', 'file') %#ok<AND2>
 
63
                if isempty(svnpath) && exist('/opt/local/bin/svn', 'file')
61
64
                        svnpath = '/opt/local/bin/';
62
65
                end
63
66
        end