standard / standard-engine

:fire_engine: The guts of `standard` modularized for reuse
MIT License
145 stars 39 forks source link

The heading of error reports have a hardcoded "Use " string added. #24

Closed gustavnikolaj closed 9 years ago

gustavnikolaj commented 9 years ago

When using standard:

$ standard foo.js
standard: Use JavaScript Standard Style (https://github.com/feross/standard) 
  /home/usernme/foo.js:1:33: Extra semicolon.

This is the code that generates the line: https://github.com/Flet/standard-engine/blob/581a4f081f9b3348f5389629543dec2e2bb94e6d/bin/cmd.js#L119-L123

The tagline of standard is "JavaScript Standard Style" - why is the Use appended?

I wanted to use standard-engine to replace an old lint setup at work. My chosen tag line does not go well with "Use" prepended to it.

Why was it chosen to hardcode part of the string? Will you be open to a pull request removing it? :-)

Flet commented 9 years ago

Totally open to changing it! I think this is an artifact of how standard-engine has evolved.

We'll just want to be sure to coordinate this change with updates to standard and semistandard (at the very least) before publishing it. Interested in hearing of folks think this would be "breaking" :)

Also, if you publish your custom linter, send a PR to add it to the README here as well! :+1:

feross commented 9 years ago

I'm fine with removing the "Use". I actually thought the same thing when I first saw that in standard-engine but forgot to change it.

I don't think it's necessary to be a major version, but that's fine too. Let's coordinate PRs to standard and semistandard though.

dcousens commented 9 years ago

IMHO not breaking

gustavnikolaj commented 9 years ago

If it's not a major version update, we do not have a chance of coordinating the update, as both standard and semi-standard is using the caret operator for the dependency on standard-engine (^2.0.4 as of writing).

I see that it might not be the biggest deal ever, but it would be nice to avoid sentences potentially double prefixed with "Use", if it was to be prefixed.

Flet commented 9 years ago

Sorry for letting this one sit here! I want to merge this and sync with standard/semistandard, but I have not had bandwidth yet :(

gustavnikolaj commented 9 years ago

With all the PR's merged, I'll go ahead and close this issue!

Thanks :-)

feross commented 9 years ago

:+1: