fix & clean imports

This commit is contained in:
cubixle
2021-06-18 21:18:00 +01:00
parent f330903f9e
commit 93a51d9365

View File

@@ -94,7 +94,7 @@ func parseProto(cfg Config) (serviceDef, error) {
importStrs := []string{} importStrs := []string{}
servicePath := filepath.Dir(cfg.GRPCFile) servicePath := filepath.Dir(cfg.GRPCFile)
for _, i := range f.Imports { for _, i := range f.Imports {
importStrs = append(importStrs, i.Path.Value) importStrs = append(importStrs, strings.Replace(i.Path.Value, `"`, "", -1))
} }
importStrs = append(importStrs, strings.Join([]string{cfg.ImportPath, strings.TrimLeft(servicePath, "/")}, "/")) importStrs = append(importStrs, strings.Join([]string{cfg.ImportPath, strings.TrimLeft(servicePath, "/")}, "/"))