Skip to content

Add support for eslint-plugin-html #173

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
artn opened this issue Feb 3, 2017 · 3 comments
Closed

Add support for eslint-plugin-html #173

artn opened this issue Feb 3, 2017 · 3 comments

Comments

@artn
Copy link

artn commented Feb 3, 2017

I am using RiotJS with ES6 and using eslint-plugin-html for linting.

When build the code on codeclimate, error was raised.

File `.eslintignore` ignored because of your .eslintignore file.
File `.eslintrc.js` ignored because of your .eslintignore file.
File `.eslintrc` ignored because of your .eslintignore file.
File `.gitignore` ignored because of your .eslintignore file.
File `.codeclimate.yml` ignored because of your .eslintignore file.
/usr/src/app/node_modules/eslint/lib/config/plugins.js:137
                throw err;
                ^

Error: Failed to load plugin html: Cannot find module 'eslint-plugin-html'
    at Function.Module._resolveFilename (module.js:455:15)
    at Function.Module._load (module.js:403:25)
    at Module.require (module.js:483:17)
    at require (internal/module.js:20:19)
    at Object.load (/usr/src/app/node_modules/eslint/lib/config/plugins.js:129:26)
    at Array.forEach (native)
    at Object.loadAll (/usr/src/app/node_modules/eslint/lib/config/plugins.js:151:21)
    at Object.load (/usr/src/app/node_modules/eslint/lib/config/config-file.js:504:21)
    at loadConfig (/usr/src/app/node_modules/eslint/lib/config.js:63:33)
    at new Config (/usr/src/app/node_modules/eslint/lib/config.js:226:38)

Could you add support for this please?

@dblandin
Copy link
Contributor

We'd be happy to look at a pull request!

https://github.com/codeclimate/codeclimate-eslint/blob/master/CONTRIBUTING.md

@artn
Copy link
Author

artn commented Mar 16, 2017

When I executed bin/yarn add eslint-plugin-html below error was raised.

$ bin/yarn add eslint-plugin-html
yarn add v0.21.3
[1/4] Resolving packages...
[2/4] Fetching packages...
error Could not write file "/usr/src/app/yarn-error.log": "EACCES: permission denied, open '/usr/src/app/yarn-error.log'"
error An unexpected error occurred: "EACCES: permission denied, unlink '/usr/src/app/node_modules/.yarn-integrity'".
info Visit https://yarnpkg.com/en/docs/cli/add for documentation about this command.

So I executed below command and found that in my docker environment(MacOS host and using docker-machine with VirtualBox driver), login user is app but mounted volume's owner is node.

$ bin/yarn add "eslint-plugin-html; ls -la ; id"
yarn add v0.21.3
[1/4] Resolving packages...
[2/4] Fetching packages...
error Could not write file "/usr/src/app/yarn-error.log": "EACCES: permission denied, open '/usr/src/app/yarn-error.log'"
error An unexpected error occurred: "EACCES: permission denied, unlink '/usr/src/app/node_modules/.yarn-integrity'".
info Visit https://yarnpkg.com/en/docs/cli/add for documentation about this command.
total 116
drwxr-xr-x 1 node staff   714 Mar 16 05:30 .
drwxr-xr-x 7 root root   4096 Mar 15 21:07 ..
-rw-r--r-- 1 node staff   214 Mar 16 04:56 .codeclimate.yml
-rw-r--r-- 1 node staff    13 Mar 16 04:56 .dockerignore
-rw-r--r-- 1 node staff   722 Mar 16 04:56 .eslintrc
drwxr-xr-x 1 node staff   442 Mar 16 05:34 .git
-rw-r--r-- 1 node staff    13 Mar 16 04:56 .gitignore
drwxr-xr-x 1 node staff   374 Mar 16 04:59 .idea
-rw-r--r-- 1 node staff   829 Mar 16 04:56 CONTRIBUTING.md
-rw-r--r-- 1 node staff  1036 Mar 16 04:56 Dockerfile
-rw-r--r-- 1 node staff  1062 Mar 16 04:56 LICENSE
-rw-r--r-- 1 node staff   352 Mar 16 04:56 Makefile
-rw-r--r-- 1 node staff  1779 Mar 16 04:56 README.md
-rw-r--r-- 1 node staff   260 Mar 16 04:56 WERE_HIRING.md
drwxr-xr-x 1 node staff   170 Mar 16 04:56 bin
-rw-r--r-- 1 node staff   721 Mar 16 04:56 circle.yml
drwxr-xr-x 1 node staff   374 Mar 16 04:56 lib
drwxr-xr-x 1 node staff  9690 Mar 16 05:33 node_modules
-rw-r--r-- 1 node staff  2383 Mar 16 05:33 package.json
drwxr-xr-x 1 node staff   306 Mar 16 04:56 test
-rw-r--r-- 1 node staff 64351 Mar 16 04:56 yarn.lock
uid=9000(app) gid=9000(app) groups=9000(app)

I'd like to know how to fix the issue.

@dblandin
Copy link
Contributor

Sorry! Looks like eslint-plugin-html was already added in #195.

You should be able to use that plugin either on codeclimate.com or via the CLI now.

There is an issue with the bin/yarn executable which I'll fix in a separate PR.

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants