@@ -64,7 +64,7 @@ function colorizeOutput (color, string) {
64
64
return color + string + RESET
65
65
}
66
66
67
- //! on windows debug running with locale cmd (e. g. chcp 866) encoding
67
+ //! on windows debug running with locale cmd encoding (e. g. chcp 866)
68
68
// to avoid that uncomment next lines
69
69
// locale encodings cause issues. See run func for more info
70
70
// this lines only for testing
@@ -312,7 +312,8 @@ class PythonFinder {
312
312
this . log . verbose (
313
313
`executing "${ colorizeOutput (
314
314
GREEN ,
315
- check . name || check . arg
315
+ // DONE: swap in favor of arg (user want to see what we actually will run not how it is named)
316
+ check . arg || check . name
316
317
) } " to get Python executable path`
317
318
)
318
319
@@ -469,6 +470,7 @@ class PythonFinder {
469
470
`${ colorizeOutput ( GREEN , 'execFile' ) } : args = %j` ,
470
471
args
471
472
)
473
+ // TODO: make beauty print of PATH property (new line by semicolon)
472
474
this . log . silly ( 'execFile: opts = ' , JSON . stringify ( opts , null , 2 ) )
473
475
474
476
//* possible outcomes with error messages on Windows (err.message, error.stack?, stderr)
@@ -504,6 +506,7 @@ class PythonFinder {
504
506
`${ colorizeOutput ( RED , 'execFile result' ) } : err =` ,
505
507
( err && err . stack ) || err
506
508
)
509
+ // TODO: add silly logs as in previous version
507
510
508
511
// executed script shouldn't pass anything to stderr if successful
509
512
if ( err || stderr ) {
@@ -645,8 +648,8 @@ function findPython (configPython, callback) {
645
648
/* findPython(null, (err, found) => {
646
649
console.log('found:', '\x1b[31m', found)
647
650
console.log('\x1b[0m')
648
- })
649
- */
651
+ })
652
+ */
650
653
module . exports = findPython
651
654
module . exports . test = {
652
655
PythonFinder : PythonFinder ,
0 commit comments