func convertName(name string, enableInitialism ...bool) string {
	if name == "" {
		return ""
	}
	enable := false
	if len(enableInitialism) != 0 {
		enable = enableInitialism[0]
	}
	var cn string
	s := strings.Split(name, "_")
	for _, v := range s {
		upperV := strings.ToUpper(v)
		if _, ok := commonInitialisms[upperV]; ok && enable {
			cn += upperV
		} else {
			if runesV := []rune(v); len(runesV) > 0 {
				for i, r := range runesV {
					if i == 0 {
						runesV[i] = unicode.ToUpper(r)
					} else {
						runesV[i] = unicode.ToLower(r)
					}
				}
				cn += string(runesV)
			}
		}
	}
	return cn
}
convertName converts the name to camel case name.
package util
import (
	"fmt"
	"strings"
	"unicode"
)
func ConvertTable(cc CMDConfig) (string, error) {
	cis, err := getColumnInfos(&cc)
	if err != nil {
		fmt.Println("get column info slice err:", err)
		return "", err
	}
	defer db.Close()
	var fields []*StructField
	for i := range cis {
		ci := cis[i]
		var tags []string
		if cc.EnableJsonTag {
			tags = append(tags, getJsonTag(ci))
		}
		if cc.EnableXmlTag {
			tags = append(tags, getXmlTag(ci))
		}
		if cc.EnableGormTag {
			tags = append(tags, getGormTag(ci))
		}
		if cc.EnableXormTag {
			tags = append(tags, getXormTag(ci))
		}
		if cc.EnableBeegoTag {
			tags = append(tags, getBeegoTag(ci))
		}
		if cc.EnableGoroseTag {
			tags = append(tags, getGoroseTag(ci))
		}
		if cc.EnableGormV2Tag && !cc.EnableGormTag {
			tags = append(tags, getGormV2Tag(ci))
		}
		field := StructField{
			Name:    convertName(ci.Name, cc.EnableInitialism),
			Type:    convertDataType(ci, &cc),
			Comment: ci.Comment,
		}
		if len(tags) > 0 {
			field.Tag = fmt.Sprintf("`%s`", strings.Join(tags, " "))
		}
		fields = append(fields, &field)
	}
	return generateCode(&cc, fields)
}
func convertDataType(ci *ColumnInfo, cc *CMDConfig) string {
	switch ci.DataType {
	case "tinyint", "smallint", "mediumint":
		if ci.IsNullable {
			if cc.EnableGureguNull {
				return gureguNullInt
			} else if cc.EnableSqlNull {
				return sqlNullInt32
			}
		}
		if ci.IsUnsigned {
			return goUint32
		}
		return goInt32
	case "int", "integer":
		if ci.IsNullable {
			if cc.EnableGureguNull {
				return gureguNullInt
			} else if cc.EnableSqlNull {
				return sqlNullInt64
			}
		}
		if ci.IsUnsigned {
			return goUint
		}
		return goInt
	case "bigint":
		if ci.IsNullable {
			if cc.EnableGureguNull {
				return gureguNullInt
			} else if cc.EnableSqlNull {
				return sqlNullInt64
			}
		}
		if ci.IsUnsigned {
			return goUint64
		}
		return goInt64
	case "json", "enum", "set", "char", "varchar", "tinytext", "text", "mediumtext", "longtext":
		if ci.IsNullable {
			if cc.EnableGureguNull {
				return gureguNullString
			} else if cc.EnableSqlNull {
				return sqlNullString
			}
		}
		return goString
	case "year", "date", "datetime", "time", "timestamp":
		if ci.IsNullable {
			if cc.EnableGureguNull {
				return gureguNullTime
			} else if cc.EnableSqlNull {
				return sqlNullTime
			}
		}
		return goTime
	case "float":
		if ci.IsNullable {
			if cc.EnableGureguNull {
				return gureguNullFloat
			} else if cc.EnableSqlNull {
				return sqlNullFloat64
			}
		}
		return goFloat32
	case "double", "real", "decimal", "numeric":
		if ci.IsNullable {
			if cc.EnableGureguNull {
				return gureguNullFloat
			} else if cc.EnableSqlNull {
				return sqlNullFloat64
			}
		}
		return goFloat64
	case "bit", "binary", "varbinary", "tinyblob", "blob", "mediumblob", "longblob":
		return goBytes
	default:
		return "unknown"
	}
}