This repository has been archived by the owner on Apr 10, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 267
Add an include
flag to only include certain messages
#71
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
By adding this option, editors have a way to run `gometalinter` and only output the results for the file being saved. Of course it also helps other use cases where you only want to check if a specific error/warning is triggered by your code. Tested this with a customised version of `vim-go` (will make a PR there as well to use this new functionality) and it works really well.
svanharmelen
pushed a commit
to svanharmelen/vim-go
that referenced
this pull request
Nov 27, 2015
1. Add the option to run the metalinter on save 2. Add the option to limit the output to the currently active buffer There is a outstanding PR with the `gometalinter` repo to add some needed logic for this: alecthomas/gometalinter#71 So I assume this PR should not be merged before that one is merged. Also this the first vimscript code I’ve ever written, so I guess this could be done a little cleaner. Especially the implementation of the `go#lint#GometaAutoSave` func doesn’t feel all that clean to me, but I’m not sure how to do this in a different/better way. So if you have any pointers, I’ll be happy to take them 😉
@alecthomas any thoughts or feedback would be great! Thx! |
alecthomas
added a commit
that referenced
this pull request
Nov 29, 2015
Add an `include` flag to only include certain messages
Thanks! |
👍 |
svanharmelen
pushed a commit
to svanharmelen/vim-go
that referenced
this pull request
Nov 29, 2015
1. Add the option to run the metalinter on save 2. Add the option to limit the output to the currently active buffer There is a outstanding PR with the `gometalinter` repo to add some needed logic for this: alecthomas/gometalinter#71 So I assume this PR should not be merged before that one is merged. Also this the first vimscript code I’ve ever written, so I guess this could be done a little cleaner. Especially the implementation of the `go#lint#GometaAutoSave` func doesn’t feel all that clean to me, but I’m not sure how to do this in a different/better way. So if you have
svanharmelen
pushed a commit
to svanharmelen/vim-go
that referenced
this pull request
Nov 29, 2015
1. Add the option to run the metalinter on save 2. Add the option to limit the output to the currently active buffer There is a outstanding PR with the `gometalinter` repo to add some needed logic for this: alecthomas/gometalinter#71 So I assume this PR should not be merged before that one is merged. Also this the first vimscript code I’ve ever written, so I guess this could be done a little cleaner. Especially the implementation of the `go#lint#GometaAutoSave` func doesn’t feel all that clean to me, but I’m not sure how to do this in a different/better way. So if you have
Closed
Note that the short flag for this has been changed to |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
By adding this option, editors have a way to run
gometalinter
and only output the results for the file being saved. Of course it also helps other use cases where you only want to check if a specific error/warning is triggered by your code.Tested this with a customised version of
vim-go
(will make a PR there as well to use this new functionality) and it works really well.