Code Monkey home page Code Monkey logo

Comments (13)

ta2edchimp avatar ta2edchimp commented on July 19, 2024

Suppressing a non zero exit code would be achieved using --no-error.

Returning with a non zero exit code / an error code when there are unused rules, is legacy behavior to ensure all available rules are covered (to be used in a commit hook, for example), optionally suppressed.

from eslint-find-rules.

ljharb avatar ljharb commented on July 19, 2024

I wouldn't call it legacy behavior; that's the primary purpose of the binary.

from eslint-find-rules.

ta2edchimp avatar ta2edchimp commented on July 19, 2024

Yeah, sorry, bad wording choice (non native english speaker).

from eslint-find-rules.

mvolkmann avatar mvolkmann commented on July 19, 2024

Sorry, I meant to say that --no-error is not working.
-n works for me, but --no-error does not.

from eslint-find-rules.

sarbbottam avatar sarbbottam commented on July 19, 2024

I guess hyphenated options have a problem, probably will make it noerror.

from eslint-find-rules.

ta2edchimp avatar ta2edchimp commented on July 19, 2024

Tests only cover shorthand options. Same for --all-available.

from eslint-find-rules.

mvolkmann avatar mvolkmann commented on July 19, 2024

-no-error works for me.
--no-error does not.

from eslint-find-rules.

sarbbottam avatar sarbbottam commented on July 19, 2024

We just merged #196, but semantic release errored out. I will release the next version manually.
--no-error should work then.

from eslint-find-rules.

sarbbottam avatar sarbbottam commented on July 19, 2024

@mvolkmann can you try --no-error with the latest 1.14.1

from eslint-find-rules.

mvolkmann avatar mvolkmann commented on July 19, 2024

Looks like it's not quite fixed.

The command that was run was:
eslint-find-rules --unused ~/.eslintrc --no-error

I got this:
npm ERR! Failed at the [email protected] efr script 'eslint-find-rules --unused
~/.eslintrc --no-error'.
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 ui-lib package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! eslint-find-rules --unused ~/.eslintrc --no-error

$ npm info eslint-find-rules version
1.14.1

On Sat, Oct 29, 2016 at 5:57 PM, Sarbbottam Bandyopadhyay <
[email protected]> wrote:

@mvolkmann https://github.com/mvolkmann can you try --no-error with the
latest 1.14.1 https://www.npmjs.com/package/eslint-find-rules


You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
#194 (comment),
or mute the thread
https://github.com/notifications/unsubscribe-auth/AAE10Dr8MkrZxPSrRxr-1NUEE3qiYEdMks5q489cgaJpZM4KkKvX
.

R. Mark Volkmann
Object Computing, Inc.

from eslint-find-rules.

sarbbottam avatar sarbbottam commented on July 19, 2024

@mvolkmann I could not reproduce the latest problem you stated.
Steps followed.

  • mkdir test-eslint-find-rules
  • cd $_
  • npm init --yes
  • npm i eslint eslint-find-rules -D
  • touch .eslintrc
  • update .eslintrc with
{
  "rules": {
    "foo-rule": [2]
  }
}
  • eslint-find-rules -u --no-error .eslintrc

No error found as per @mvolkmann last comment.

However, the exit status was 1 instead of 0. Thus reopening the issue.
#199 should resolve the issue.

from eslint-find-rules.

sarbbottam avatar sarbbottam commented on July 19, 2024

@mvolkmann could you try with 1.14.3 and let us know.

from eslint-find-rules.

mvolkmann avatar mvolkmann commented on July 19, 2024

That works! Thanks!

On Mon, Oct 31, 2016 at 12:09 AM, Sarbbottam Bandyopadhyay <
[email protected]> wrote:

@mvolkmann https://github.com/mvolkmann could you try with 1.14.3
https://www.npmjs.com/package/eslint-find-rules and let us know.


You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
#194 (comment),
or mute the thread
https://github.com/notifications/unsubscribe-auth/AAE10GajjO8oFii0areq1RdZWEPK7LD0ks5q5Xf0gaJpZM4KkKvX
.

R. Mark Volkmann
Object Computing, Inc.

from eslint-find-rules.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.