mdempsky / unconvert

Remove unnecessary type conversions from Go source
BSD 3-Clause "New" or "Revised" License
377 stars 26 forks source link

added oneliners flag #2

Closed dmoklaf closed 8 years ago

dmoklaf commented 8 years ago

Added a "oneliners" flag to follow the tradition of most Go tools, i.e., output one line per case

dmitshur commented 8 years ago

tradition of most Go tools

Can you post a few examples? This is the first time I see such a flag.

dmoklaf commented 8 years ago

Hello, sorry for the gofmt, I will add it.

Here is a list of the tools I use, all of them excepted one (dupl) output 1 line per case by default. The exceptional one, dupl, has a specific "plumbing" flag to output 1 line per case. I invented the "one-liner" name, please feel free to choose whatever name sounds right.

gofmt go tool vet golint errcheck interfacer copyrighter align check structcheck varcheck ineffassign dupl misspell

dmitshur commented 8 years ago

Ah, the "tradition" you were referring to is to output a single line per result, it wasn't about having a "oneliners" flag. I misunderstood.

dominikh commented 8 years ago

One term I see used for this from time to time is "quickfix", because of the vim feature and the format associated with it. Clang uses -fno-caret-diagnostics I believe, but that's obviously not a good choice here.

mdempsky commented 8 years ago

Thanks for the feedback. I've changed the default behavior better match other tools, and the extra line/caret output is behind a -v flag now.

dmoklaf commented 8 years ago

great thanks