eslint: `eslint --init` failed

Tell us about your environment

  • ESLint Version: 5.16.0
  • Node Version: v10.16.0
  • npm Version: 6.9.0

What did you do? Please include the actual source code causing the issue, as well as the command that you used to run ESLint.

$ npx eslint --init
? How would you like to use ESLint? To check syntax, find problems, and enforce code style
? What type of modules does your project use? JavaScript modules (import/export)
? Which framework does your project use? React
? Where does your code run? (Press <space> to select, <a> to toggle all, <i> to invert selection)Browser
? How would you like to define a style for your project? Answer questions about your style
? What format do you want your config file to be in? JavaScript
? What style of indentation do you use? (Use arrow keys)
❯ Tabs
  Spaces

What did you expect to happen?

ESLint inits successfully.

What actually happened? Please include the actual, raw output from ESLint.

No more response when I wanna choose Spaces. The whole terminal was just dead. Even I press control+c, it doesn’t respond.

Are you willing to submit a pull request to fix this bug?

No idea.

About this issue

  • Original URL
  • State: closed
  • Created 5 years ago
  • Comments: 16 (5 by maintainers)

Most upvoted comments

I experienced the same error. Stuck at Would you like to install them now with npm? (Y/n) (nothing happen when press keys, even Ctrl + C).

  • OS: MacOS Mojave
  • ESLint Version: 5.16.0
  • Node Version: v10.15.3
  • npm Version: 6.9.0

Hi. This has been identified as an upstream bug: https://github.com/SBoudrias/Inquirer.js/issues/811

Please wait for the upstream fix.

A workaround, for now, is to install the previous version of inquirer manually:

npm install inquirer@6.3

Ah… OK. Looks like a regression of inquirer 6.4.0. If you install inquirer@6.3 manually, eslint --init works fine.