Shorten relative paths in warning texts
Closed this issue · 0 comments
quasilyte commented
Given this warning text:
$GOPATH/src/github.com/go-critic/checkers/testdata/_integration/main_only/main.go:4:9: unslice: could simplify xs[:] to xs
...and granted that the checker was run from the main_only
directory.
We can simplify the output to the:
./main_only/main.go:4:9: unslice: could simplify xs[:] to xs
This should only happen if -shorterErrLocation
flag is set to true
.