I’m attempting to get a local eslintrc
(in my project root) to extend my global eslintrc
(located at ~/.eslintrc
).
Here’s the local eslintrc
:
{
"extends": "~/.eslintrc"
}
Here’s the error I’m getting when running eslint foo.js
:
Cannot read config file: /Users/cbickel1/dev/learning/webpack-demo/~/.eslintrc
Error: ENOENT: no such file or directory, open '/Users/cbickel1/dev/learning/webpack-demo/~/.eslintrc'
Referenced from: /Users/cbickel1/dev/learning/webpack-demo/.eslintrc
Error: Cannot read config file: /Users/cbickel1/dev/learning/webpack-demo/~/.eslintrc
Error: ENOENT: no such file or directory, open '/Users/cbickel1/dev/learning/webpack-demo/~/.eslintrc'
Referenced from: /Users/cbickel1/dev/learning/webpack-demo/.eslintrc
at Object.fs.openSync (fs.js:558:18)
at Object.fs.readFileSync (fs.js:468:33)
at readFile (/Users/cbickel1/.nvm/versions/node/v7.4.0/lib/node_modules/eslint/lib/config/config-file.js:70:24)
at loadLegacyConfigFile (/Users/cbickel1/.nvm/versions/node/v7.4.0/lib/node_modules/eslint/lib/config/config-file.js:142:44)
at loadConfigFile (/Users/cbickel1/.nvm/versions/node/v7.4.0/lib/node_modules/eslint/lib/config/config-file.js:222:22)
at load (/Users/cbickel1/.nvm/versions/node/v7.4.0/lib/node_modules/eslint/lib/config/config-file.js:505:18)
at configExtends.reduceRight (/Users/cbickel1/.nvm/versions/node/v7.4.0/lib/node_modules/eslint/lib/config/config-file.js:391:36)
at Array.reduceRight (native)
at applyExtends (/Users/cbickel1/.nvm/versions/node/v7.4.0/lib/node_modules/eslint/lib/config/config-file.js:362:28)
at Object.load (/Users/cbickel1/.nvm/versions/node/v7.4.0/lib/node_modules/eslint/lib/config/config-file.js:536:22)
Looks like ESLint isn’t correctly resolving the path given as absolute. What should I do?
ESLint as of release v4.7.0 does not support project root.
Looking at the source, you either need to provide an absolute or relative path from the
.eslintrc
file.Source: https://github.com/eslint/eslint/blob/v4.7.0/lib/config/config-file.js#L413
Examples
Absolute (Windows)
Absolute (Mac/Linux)
Relative
buy tadalafil – viagra vs tadalafil online tadalafil
buy tadalafil 20mg price – http://xtadalafilp.com/ buy tadalafil pills
Iebaks – what does an annotated bibliography look like apa Cphcxc txcqis
Dgyixb – erectile dysfunction causes Hjdmeq gfdllw
Zkhtnp – furosempi.com Okstlk pwpozp
Wcxwuz – female viagra pill for sale Jyrpof wrbofn
Blsykz – help homework math Dglerw uzhgsa
Hpwtwh – viagra medicine Xobxrq ianpvf
Wiamep – generic finasteride over the counter walgreens Yxmdxd yijhct
Kqabcr – commander viagra pfizer Qmdmva oyczqo
Nadbsu – genesis finasteride usp 1mg Bzuajz uswfhv
Tfnjin – research paper parts Gkzitk eqzueb
Gitsjv – taking sildenafil Uczlpo fngdts
Rzcsal – gshlsbcv Xchhcy tqkxks
Wqnqmo – furosemida 40 mg Sgjhid hawahd
Bpqkhv – buy vardenafil new zealand Fsvgzb bxgrdd
Ueqpre – cheap silagra Agfgoi tueeik
Cikxjy – can i buy tadacip without rx Dczqmf hltcwy
Xfabit – avana 200 Vluquj mejkox