diff --git a/lib/watson.js b/lib/watson.js index b322cdc..2f7f4a8 100644 --- a/lib/watson.js +++ b/lib/watson.js @@ -74,8 +74,11 @@ function transform(files, transformFormula) { fs.writeFileSync(file, newSource); } - } catch (err) { - wontFix.push(file); + } catch (error) { + wontFix.push({ + name: file, + error: error.message + }); } }, this); @@ -85,7 +88,7 @@ function transform(files, transformFormula) { ); wontFix.forEach(function(file) { - console.log(chalk.red(file)); + console.log(chalk.red(file.name + ' - ' + file.error)); }); console.log(chalk.red('\nA possible cause is having all the source code commented.'));