Skip to content

Commit 7063a9d

Browse files
dgolubjirfag
authored andcommitted
Fix errors when specifying absolute path
1 parent 99329fb commit 7063a9d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pkg/lint/load.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ func (cl ContextLoader) buildArgs() []string {
182182

183183
var retArgs []string
184184
for _, arg := range args {
185-
if strings.HasPrefix(arg, ".") {
185+
if strings.HasPrefix(arg, ".") || filepath.IsAbs(arg) {
186186
retArgs = append(retArgs, arg)
187187
} else {
188188
// go/packages doesn't work well if we don't have prefix ./ for local packages

0 commit comments

Comments
 (0)