From 54f4301ddfc884a7eac5b6ebf68868d6078279d3 Mon Sep 17 00:00:00 2001 From: Luke Shumaker Date: Sat, 4 Sep 2021 08:39:09 -0600 Subject: [PATCH] gci: Parse the settings more similarly to the cli (#2217) --- pkg/golinters/gci.go | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/pkg/golinters/gci.go b/pkg/golinters/gci.go index 49effb81..9886fc5f 100644 --- a/pkg/golinters/gci.go +++ b/pkg/golinters/gci.go @@ -3,7 +3,6 @@ package golinters import ( "bytes" "fmt" - "strings" "sync" "github.com/daixiang0/gci/pkg/gci" @@ -47,9 +46,8 @@ func NewGci() *goanalysis.Linter { var issues []goanalysis.Issue - flagSet := gci.FlagSet{} - if localFlag != "" { - flagSet.LocalFlag = strings.Split(localFlag, ",") + flagSet := gci.FlagSet{ + LocalFlag: gci.ParseLocalFlag(localFlag), } for _, f := range fileNames {