golangci-lint icon indicating copy to clipboard operation
golangci-lint copied to clipboard

Support SuggestedFixes

Open SVilgelm opened this issue 2 years ago • 2 comments

Conver the SuggesterFixes to Replacement by:

  1. applying the fixes to a file in memory
  2. creating a diff by comparing with original file
  3. using ExtractIssuesFromPatch function to create the issues

SVilgelm avatar Feb 22 '22 04:02 SVilgelm

@ldez Ok, the PR is ready. I understand that the solution is not the best possible, but I still don't understand how to manually create a Replacement object for a TextEdit. This is kind of workaround

PS: gci does not provide SuggestedFixes :(

SVilgelm avatar Feb 22 '22 16:02 SVilgelm

@SVilgelm

PS: gci does not provide SuggestedFixes :(

Is that fixed in PR #1490 ? At least a replacement is provided there, so maybe it can be improved from there on after merging?

nightlyone avatar May 19 '22 18:05 nightlyone