@@ -26,8 +26,8 @@ PythonFinder.prototype = {
2626 win : win ,
2727 pyLauncher : 'py.exe' ,
2828 winDefaultLocations : [
29- path . join ( process . env . SystemDrive || 'C:' , 'Python27 ' , 'python.exe' ) ,
30- path . join ( process . env . SystemDrive || 'C:' , 'Python37 ' , 'python.exe' )
29+ path . join ( process . env . SystemDrive || 'C:' , 'Python37 ' , 'python.exe' ) ,
30+ path . join ( process . env . SystemDrive || 'C:' , 'Python27 ' , 'python.exe' )
3131 ] ,
3232
3333 // Logs a message at verbose level, but also saves it to be displayed later
@@ -88,14 +88,14 @@ PythonFinder.prototype = {
8888 arg : this . env . PYTHON
8989 } ,
9090 {
91- before : ( ) => { this . addLog ( 'checking if "python " can be used' ) } ,
91+ before : ( ) => { this . addLog ( 'checking if "python3 " can be used' ) } ,
9292 check : this . checkCommand ,
93- arg : 'python '
93+ arg : 'python3 '
9494 } ,
9595 {
96- before : ( ) => { this . addLog ( 'checking if "python3 " can be used' ) } ,
96+ before : ( ) => { this . addLog ( 'checking if "python " can be used' ) } ,
9797 check : this . checkCommand ,
98- arg : 'python3 '
98+ arg : 'python '
9999 } ,
100100 {
101101 before : ( ) => { this . addLog ( 'checking if "python2" can be used' ) } ,
@@ -105,13 +105,6 @@ PythonFinder.prototype = {
105105 ]
106106
107107 if ( this . win ) {
108- checks . push ( {
109- before : ( ) => {
110- this . addLog (
111- 'checking if the py launcher can be used to find Python 2' )
112- } ,
113- check : this . checkPyLauncher
114- } )
115108 for ( var i = 0 ; i < this . winDefaultLocations . length ; ++ i ) {
116109 const location = this . winDefaultLocations [ i ]
117110 checks . push ( {
@@ -123,6 +116,13 @@ PythonFinder.prototype = {
123116 arg : location
124117 } )
125118 }
119+ checks . push ( {
120+ before : ( ) => {
121+ this . addLog (
122+ 'checking if the py launcher can be used to find Python 2' )
123+ } ,
124+ check : this . checkPyLauncher
125+ } )
126126 }
127127
128128 return checks
0 commit comments