Skip to content
This repository has been archived by the owner on Oct 28, 2020. It is now read-only.

feat: log version, module, and files #59

Merged
merged 2 commits into from
Sep 9, 2018
Merged

feat: log version, module, and files #59

merged 2 commits into from
Sep 9, 2018

Conversation

brandonocasey
Copy link
Contributor

Proposed Changes

I saw that there was a verbose option and I think that it would be useful to print the files checked, the version checked with, and if module was used or not.

Copy link
Contributor

@yowainwright yowainwright left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@brandonocasey awesome stuff!

I noticed a few things. Fix those and we're good to go. 💪

index.js Outdated
@@ -106,6 +106,8 @@ prog
const acornOpts = { ecmaVersion: e, silent: true }
if (esmodule) { acornOpts.sourceType = 'module'}

logger.debug(`ES-Check: Going to check files using version ${e} with module = ${esmodule || 'false'}`)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

logger.debug(`ES-Check: Going to check files using version ${e}${esmodule ? ' with esmodule set' : ''}`)

index.js Outdated
@@ -114,6 +116,8 @@ prog

globbedFiles.forEach((file) => {
const code = fs.readFileSync(file, 'utf8')

logger.debug(`ES-Check: checking ${file} `)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove space after ${file}.

@yowainwright
Copy link
Contributor

@brandonocasey, thanks for this thoughtful PR.

@yowainwright yowainwright merged commit 3de6d31 into dollarshaveclub:master Sep 9, 2018
@brandonocasey brandonocasey deleted the feat/verbose branch September 10, 2018 02:31
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants