diff --git a/data/view/genstruct/common.go b/data/view/genstruct/common.go index f61b068..6ac64b0 100644 --- a/data/view/genstruct/common.go +++ b/data/view/genstruct/common.go @@ -158,8 +158,12 @@ func (s *GenStruct) GeneratesColor() []string { } p.Add("\033[32;1m " + s.Notes + " \033[0m") p.Add("\033[34;1m type \033[0m", s.Name, "\033[34;1m struct \033[0m {") + mp := make(map[string]bool, len(s.Em)) for _, v := range s.Em { - p.Add(" \t\t" + v.GenerateColor()) + if !mp[v.Name] { + mp[v.Name] = true + p.Add(" \t\t" + v.GenerateColor()) + } } p.Add(" }") diff --git a/gormt b/gormt new file mode 100755 index 0000000..40f268b Binary files /dev/null and b/gormt differ