You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Mar 25, 2021. It is now read-only.
Anything that causes a lint error the lint error performs but an error occurs when it is finished.
`npm ERR! Darwin 14.5.0
npm ERR! argv "/Users/my/.nvm/versions/node/v6.2.2/bin/node" "/Users/my/.nvm/versions/node/v6.2.2/bin/npm" "run" "lint"
npm ERR! node v6.2.2
npm ERR! npm v3.9.5
npm ERR! code ELIFECYCLE
npm ERR! my-application@1.0.0 lint: `tslint "src/**/*.ts"`
npm ERR! Exit status 2
npm ERR!
npm ERR! Failed at the my-application@1.0.0 lint script 'tslint "src/**/*.ts"'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the my-application package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! tslint "src/**/*.ts"
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs my-application
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls my-application
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! /Users/my/my/my/frontend/npm-debug.log
Expected behavior
The error shouldn't occur when it is finished.
The text was updated successfully, but these errors were encountered:
IllusionMH
Yes I do have lint errors above... but why would it release such a horrible message after finding errors? but yes --force works... why not a summary or something... rather than exit 2
@xt0rted this is standard npm error (in this case npm script error) if launched process exits with code other than 0.
You can try to run TSLint directly from CLI to see that it only reports lint errors: ./node_modules/.bin/tslint "src/**/*.ts"
You can also check this comment from GitHub Issue in npm repository npm/npm#6124 (comment) and use -s/--silent flag to suppress that verbose error.
So this issue is not related to TSLint directly.
UPD. Exit codes are established practice to control execution flow of several commands. And it is regular practice to avoid long compilation and tests execution if your code doesn't pass code style checks.
@IllusionMH is right (thanks for the comments here!). Closing this out as this is working as intended and the NPM script questions are external to this project.
Bug Report
2.1.1
TypeScript code being linted
with
tslint.json
configuration:Actual behavior
Anything that causes a lint error the lint error performs but an error occurs when it is finished.
Expected behavior
The error shouldn't occur when it is finished.
The text was updated successfully, but these errors were encountered: